From: Thorsten Engel Date: Mon, 24 Apr 2006 10:35:57 +0000 (+0000) Subject: - buffer bug (found by Christopher Hull) X-Git-Tag: Release-2.0.0~917 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=004447f83a9647066c1ffd915d1b1ced5c4f7fb5;p=bacula%2Fbacula - buffer bug (found by Christopher Hull) git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@2963 91ce42f0-d328-0410-95d8-f526ca767f89 --- diff --git a/bacula/src/win32/compat/compat.cpp b/bacula/src/win32/compat/compat.cpp index 894c3ed47e..0dc526753a 100644 --- a/bacula/src/win32/compat/compat.cpp +++ b/bacula/src/win32/compat/compat.cpp @@ -974,7 +974,7 @@ readdir_r(DIR *dirp, struct dirent *entry, struct dirent **result) // copy unicode if (dp->valid_w) { - char szBuf[MAX_PATH_UTF8]; + char szBuf[MAX_PATH_UTF8+1]; wchar_2_UTF8(szBuf,dp->data_w.cFileName); dp->offset += copyin(*entry, szBuf); } else if (dp->valid_a) { // copy ansi (only 1 will be valid)