File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -193,13 +193,11 @@ ALLEGRO_BITMAP *al_load_bitmap_flags(const char *filename, int flags)
193
193
Handler * h ;
194
194
ALLEGRO_BITMAP * ret ;
195
195
196
- ext = strrchr (filename , '.' );
196
+ ext = al_identify_bitmap (filename );
197
197
if (!ext ) {
198
- ext = al_identify_bitmap (filename );
198
+ ext = strrchr (filename , '.' );
199
199
if (!ext ) {
200
- ALLEGRO_ERROR ("Bitmap %s has no extension and filetype "
201
- "identification failed - not even trying to load it.\n" ,
202
- filename );
200
+ ALLEGRO_ERROR ("Could not identify bitmap %s!" , filename );
203
201
return NULL ;
204
202
}
205
203
}
@@ -208,12 +206,11 @@ ALLEGRO_BITMAP *al_load_bitmap_flags(const char *filename, int flags)
208
206
if (h && h -> loader ) {
209
207
ret = h -> loader (filename , flags );
210
208
if (!ret )
211
- ALLEGRO_ERROR ("Failed loading %s with %s handler.\n" , filename ,
212
- ext );
209
+ ALLEGRO_ERROR ("Failed loading bitmap %s with %s handler.\n" ,
210
+ filename , ext );
213
211
}
214
212
else {
215
- ALLEGRO_ERROR ("No handler for bitmap extension %s - "
216
- "therefore not trying to load %s.\n" , ext , filename );
213
+ ALLEGRO_ERROR ("No handler for bitmap %s!" , filename );
217
214
ret = NULL ;
218
215
}
219
216
You can’t perform that action at this time.
0 commit comments