X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=image.c;h=d5123408c96141dd56849b2e5b29bc0321c53407;hb=4f0f1d15ebb91d53c1d449cf96f6be3791566edc;hp=6bca15aa45ae45a73179c278d5e657b07b3524c7;hpb=542f6670e0f2250b940e987348b8c454c59495a2;p=xonotic%2Fdarkplaces.git diff --git a/image.c b/image.c index 6bca15aa..d5123408 100644 --- a/image.c +++ b/image.c @@ -849,6 +849,10 @@ unsigned char *loadimagepixelsbgra (const char *filename, qboolean complain, qbo Con_Printf(format == firstformat ? "\"%s\"" : (format[1].formatstring ? ", \"%s\"" : " or \"%s\".\n"), format->formatstring); } } + + // texture loading can take a while, so make sure we're sending keepalives + CL_KeepaliveMessage(false); + if (developer_memorydebug.integer) Mem_CheckSentinelsGlobal(); return NULL; @@ -873,7 +877,7 @@ int fixtransparentpixels(unsigned char *data, int w, int h) int const FIXTRANS_HAS_U = 8; int const FIXTRANS_HAS_D = 16; int const FIXTRANS_FIXED = 32; - unsigned char *fixMask = Mem_Alloc(tempmempool, w * h); + unsigned char *fixMask = (unsigned char *) Mem_Alloc(tempmempool, w * h); int fixPixels = 0; int changedPixels = 0; int x, y; @@ -1017,6 +1021,7 @@ void Image_FixTransparentPixels_f(void) Con_Printf("unchanged.\n"); Mem_Free(data); } + FS_FreeSearch(search); } qboolean Image_WriteTGABGR_preflipped (const char *filename, int width, int height, const unsigned char *data, unsigned char *buffer)