]> de.git.xonotic.org Git - xonotic/netradiant.git/blobdiff - plugins/vfspk3/vfs.cpp
plugin/vfspk3: prevent buffer overflow/stack smashing
[xonotic/netradiant.git] / plugins / vfspk3 / vfs.cpp
index ded3d048f817a5278b0dec1f05762c96339965f2..44c2ebb5290630fe13f17d1415773c27f55dc8eb 100644 (file)
@@ -562,7 +562,7 @@ void InitDirectory( const char* directory, ArchiveModules& archiveModules ){
                                }
 
                                const char *ext = strrchr( name, '.' );
-                               char tmppath[PATH_MAX];
+                               char tmppath[PATH_MAX + 1];
 
                                if ( ext != nullptr ) {
                                        if ( is_dpk_vfs && !string_compare_nocase_upper( ext, ".dpkdir" ) ) {