]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - image.c
fix a bug in texture path identification (the nopath case was occurring
[xonotic/darkplaces.git] / image.c
diff --git a/image.c b/image.c
index 7f5ed1fcf3b8344fa88590804061916a2d42139f..be151e7892bbc8d4e018e0753bcca08ecf935a11 100644 (file)
--- a/image.c
+++ b/image.c
@@ -865,7 +865,7 @@ unsigned char *loadimagepixels (const char *filename, qboolean complain, int mat
                firstformat = imageformats_textures;
        else if (!strcasecmp(name, "gfx"))
                firstformat = imageformats_gfx;
-       else if (!strchr(name, '/'))
+       else if (!strchr(basename, '/'))
                firstformat = imageformats_nopath;
        else
                firstformat = imageformats_other;