Fossil

View Ticket
Login

View Ticket

Ticket Hash: 9c3e2a224b6b0055b6bce9f46aafc03248f30524
Title: SIGSEGV on pull
Status: Fixed Type: Code_Defect
Severity: Severe Priority:
Subsystem: Resolution: Fixed
Last Modified: 2011-06-11 05:07:49
Version Found In: 621be704940afeef6d02c3615c07a2ee4f54edfc
Description:
Doing a simple 'fossil pull' on my reva repo (http://dev.ronware.org/p/reva) gave me a segv:
Program received signal SIGSEGV, Segmentation fault.
fossil_strcmp (zA=<value optimized out>, zB=<value optimized out>) at ./bld/printf_.c:862
862           b = *zB++;
(gdb) bt
#0  fossil_strcmp (zA=<value optimized out>, zB=<value optimized out>) at ./bld/printf_.c:862
#1  0x0807f816 in manifest_file_seek_base (p=0x841ac60, zName=0xb7afd14e <Address 0xb7afd14e out of bounds>) at ./bld/manifest_.c:1162
#2  0x080827a7 in manifest_file_seek (pid=<value optimized out>, pParent=0x841ac60, cid=3871, pChild=0x8411a58) at ./bld/manifest_.c:1199
#3  add_mlink (pid=<value optimized out>, pParent=0x841ac60, cid=3871, pChild=0x8411a58) at ./bld/manifest_.c:1301
#4  0x08083eea in manifest_crosslink (rid=3893, pContent=0xbffff368) at ./bld/manifest_.c:1566
#5  0x080b346a in xfer_accept_file (pXfer=0xbffff430, cloneFlag=<value optimized out>) at ./bld/xfer_.c:182
#6  0x080b5762 in client_sync (pushFlag=<value optimized out>, pullFlag=<value optimized out>, cloneFlag=0, privateFlag=0, configRcvMask=0, 
    configSendMask=0) at ./bld/xfer_.c:1463
#7  0x0809a953 in pull_cmd () at ./bld/sync_.c:164
#8  0x0807e0f5 in main (argc=2, argv=0xbffff714) at ./bld/main_.c:290


ron added on 2011-06-08 18:00:38 UTC:
Doing a 'clone' against that repo works fine, it's just 'pull' that segvs


drh added on 2011-06-09 19:45:06 UTC:
Note: The OP sent me the faulty repository.

The segfault is fixed by [05389804886bba19776938c5350e0043a1f97239]. After applying that fix, the "pull" operation goes into an infinite loop. This was traced to the fact that the repository database is corrupt. (Dunno how that happened!) The corruption can be fixed by running "REINDEX" in the SQLite shell for the repository. Once the corruption is repaired, the "pull" command works.


anonymous added on 2011-06-11 05:07:49 UTC:

test