- off_t iPos = stream.TellI();
- stream.SeekI (0);
- stream.Read(hdr, 4);
- stream.SeekI(iPos);
- //hdr[2] is one for an icon and two for a cursor
- return (hdr[0] == '\0' && hdr[1] == '\0' && hdr[2] == '\1' && hdr[3] == '\0');
+ if ( !stream.Read(hdr, WXSIZEOF(hdr)) )
+ return FALSE;
+
+ // hdr[2] is one for an icon and two for a cursor
+ return hdr[0] == '\0' && hdr[1] == '\0' && hdr[2] == '\1' && hdr[3] == '\0';