Skip to content

Commit 43c6128

Browse files
committed
MB-45882: [Windows] - Indexes are missing
After doing offline upgrade from 6.6.2 -> 7.0.0 indexes are missing. The issue is in the function "compactor_get_actual_filename". The call to FindFirstFiles uses the filename and not the full path. This may result in not getting the list of files in the directory. If no file is found a new file is created and used. That will not have the data that was moved to the new file causing the missing indexes problem. The reason is when indemetadata Change-Id: I659ba2454a4136c29b28fe61768513313db390ff Reviewed-on: http://review.couchbase.org/c/forestdb/+/152927 Tested-by: Build Bot <[email protected]> Reviewed-by: Srinath Duvuru <[email protected]>
1 parent 9e3d919 commit 43c6128

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/compactor.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1010,8 +1010,8 @@ fdb_status compactor_get_actual_filename(const char *filename,
10101010
HANDLE hfind;
10111011
char query_str[MAX_FNAMELEN];
10121012

1013-
// find all files start with 'prefix'
1014-
sprintf(query_str, "%s*", prefix);
1013+
// find all files start with 'prefix'
1014+
sprintf(query_str, "%s*", filename);
10151015
hfind = FindFirstFile(query_str, &filedata);
10161016
while (hfind != INVALID_HANDLE_VALUE) {
10171017
if (!strncmp(filedata.cFileName, prefix, strlen(prefix))) {

0 commit comments

Comments
 (0)