]> de.git.xonotic.org Git - xonotic/netradiant.git/blobdiff - tools/quake3/q3map2/image.c
ported over the 1.5 branch version of q3map2 which is newer
[xonotic/netradiant.git] / tools / quake3 / q3map2 / image.c
index fec9f6f5e4eae708e19b1115ab929653f28c07dc..0ddcaf86bc59e556fa7d3e2cb5127a95dfdf1b00 100644 (file)
@@ -1,4 +1,5 @@
-/*
+/* -------------------------------------------------------------------------------
+
 Copyright (C) 1999-2007 id Software, Inc. and contributors.
 For a list of contributors, see the accompanying CONTRIBUTORS file.
 
@@ -390,7 +391,7 @@ image_t *ImageLoad( const char *filename )
        strcat( name, ".tga" );
        size = vfsLoadFile( (const char*) name, (void**) &buffer, 0 );
        if( size > 0 )
-               LoadTGABuffer( buffer, &image->pixels, &image->width, &image->height );
+               LoadTGABuffer( buffer, buffer + size, &image->pixels, &image->width, &image->height );
        else
        {
                /* attempt to load png */