Commit 1022db2b by Vicent Marti

refdb_fs: Traits are always surrounded by spaces

This makes parsing easier! :p
parent f69db390
......@@ -219,9 +219,9 @@ static int packed_load(refdb_fs_backend *backend)
const char *traits = buffer_start + strlen(traits_header);
const char *traits_end = strchr(traits, '\n');
if (strstr(traits, "fully-peeled") != NULL) {
if (strstr(traits, " fully-peeled ") != NULL) {
backend->peeling_mode = PEELING_FULL;
} else if (strstr(traits, "peeled") != NULL) {
} else if (strstr(traits, " peeled ") != NULL) {
backend->peeling_mode = PEELING_STANDARD;
}
......
......@@ -26,7 +26,7 @@
#define GIT_SYMREF "ref: "
#define GIT_PACKEDREFS_FILE "packed-refs"
#define GIT_PACKEDREFS_HEADER "# pack-refs with: peeled fully-peeled"
#define GIT_PACKEDREFS_HEADER "# pack-refs with: peeled fully-peeled "
#define GIT_PACKEDREFS_FILE_MODE 0666
#define GIT_HEAD_FILE "HEAD"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment