out.write(buf, sizeof(buf));
out.write(reinterpret_cast<char *>(buf), sizeof(buf));
static void Write_palette	(	ostream& out,	GdkRgbCmap *pal			// Palette to write.	)	{	unsigned char buf[3*256];	// 3 bytes/color.	for (int i = 0; i < 256; i++)		{		int r = (pal->colors[i]>>16)&255,		    g = (pal->colors[i]>>8)&255,		    b = pal->colors[i]&255;		buf[3*i] = r/4;		// Range 0-63.		buf[3*i + 1] = g/4;		buf[3*i + 2] = b/4;		}	out.write(buf, sizeof(buf));	}