Fossil

Check-in [f8f5a815]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Show all files in fusefs directory listings. Previously, if one file's name is a prefix of another file's name in the same directory, the file with the longer name is not included in directory listings.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: f8f5a8159ee934f10a85c9629d5a102bd54f23f9
User & Date: andygoth 2016-10-14 20:32:06
Original Comment: Show all files in fusefs directory listings. Previously, if one file's name is a prefix of another file's name in the same directory, the file with the longer name would not be included in directory listings.
Context
2016-10-14
20:34
Merge fork check-in: 3a35ac58 user: andygoth tags: trunk
20:32
Show all files in fusefs directory listings. Previously, if one file's name is a prefix of another file's name in the same directory, the file with the longer name is not included in directory listings. check-in: f8f5a815 user: andygoth tags: trunk
2016-10-13
14:52
Change webui.wiki to remove the exception about the download page, which is no longer the case. check-in: 47beb495 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/fusefs.c.

205
206
207
208
209
210
211
212

213
214
215
216
217
218
219
  fusefs_load_rid(rid, fusefs.az[1]);
  if( fusefs.pMan==0 ) return -ENOENT;
  filler(buf, ".", NULL, 0);
  filler(buf, "..", NULL, 0);
  manifest_file_rewind(fusefs.pMan);
  if( n==2 ){
    while( (pFile = manifest_file_next(fusefs.pMan, 0))!=0 ){
      if( nPrev>0 && strncmp(pFile->zName, zPrev, nPrev)==0 ) continue;

      zPrev = pFile->zName;
      for(nPrev=0; zPrev[nPrev] && zPrev[nPrev]!='/'; nPrev++){}
      z = mprintf("%.*s", nPrev, zPrev);
      filler(buf, z, NULL, 0);
      fossil_free(z);
      cnt++;
    }







|
>







205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
  fusefs_load_rid(rid, fusefs.az[1]);
  if( fusefs.pMan==0 ) return -ENOENT;
  filler(buf, ".", NULL, 0);
  filler(buf, "..", NULL, 0);
  manifest_file_rewind(fusefs.pMan);
  if( n==2 ){
    while( (pFile = manifest_file_next(fusefs.pMan, 0))!=0 ){
      if( nPrev>0 && strncmp(pFile->zName, zPrev, nPrev)==0
                  && pFile->zName[nPrev]=='/' ) continue;
      zPrev = pFile->zName;
      for(nPrev=0; zPrev[nPrev] && zPrev[nPrev]!='/'; nPrev++){}
      z = mprintf("%.*s", nPrev, zPrev);
      filler(buf, z, NULL, 0);
      fossil_free(z);
      cnt++;
    }