Fossil SCM

Enquote the requested path glob in query to get history for a directory name with spaces.

ashepilko 2020-05-09 18:08 trunk
Commit 972341dbca1844bd7fd5522369bcb1d906eed7d89a966090f1f575665838b374
1 file changed +1 -1
+1 -1
--- src/timeline.c
+++ src/timeline.c
@@ -1312,11 +1312,11 @@
13121312
){
13131313
if( zChng==0 || zChng[0]==0 ) return;
13141314
blob_append_sql(pSql," AND event.objid IN ("
13151315
"SELECT mlink.mid FROM mlink, filename"
13161316
" WHERE mlink.fnid=filename.fnid AND %s)",
1317
- glob_expr("filename.name", zChng));
1317
+ glob_expr("filename.name", mprintf("\"%s\"", zChng)));
13181318
}
13191319
static void addFileGlobDescription(
13201320
const char *zChng, /* The filename GLOB list */
13211321
Blob *pDescription /* Result description */
13221322
){
13231323
--- src/timeline.c
+++ src/timeline.c
@@ -1312,11 +1312,11 @@
1312 ){
1313 if( zChng==0 || zChng[0]==0 ) return;
1314 blob_append_sql(pSql," AND event.objid IN ("
1315 "SELECT mlink.mid FROM mlink, filename"
1316 " WHERE mlink.fnid=filename.fnid AND %s)",
1317 glob_expr("filename.name", zChng));
1318 }
1319 static void addFileGlobDescription(
1320 const char *zChng, /* The filename GLOB list */
1321 Blob *pDescription /* Result description */
1322 ){
1323
--- src/timeline.c
+++ src/timeline.c
@@ -1312,11 +1312,11 @@
1312 ){
1313 if( zChng==0 || zChng[0]==0 ) return;
1314 blob_append_sql(pSql," AND event.objid IN ("
1315 "SELECT mlink.mid FROM mlink, filename"
1316 " WHERE mlink.fnid=filename.fnid AND %s)",
1317 glob_expr("filename.name", mprintf("\"%s\"", zChng)));
1318 }
1319 static void addFileGlobDescription(
1320 const char *zChng, /* The filename GLOB list */
1321 Blob *pDescription /* Result description */
1322 ){
1323

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button