grsync crashes on save session

Bug #148272 reported by Stefano Karapetsas
62
Affects Status Importance Assigned to Milestone
grsync (Fedora)
Fix Released
Low
grsync (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

Binary package hint: grsync

I set up grsync, and when I save session, grsynch crashes

ProblemType: Crash
Architecture: i386
Date: Tue Oct 2 22:38:25 2007
DistroRelease: Ubuntu 7.10
ExecutablePath: /usr/bin/grsync
NonfreeKernelModules: nvidia
Package: grsync 0.6-1
PackageArchitecture: i386
ProcCmdline: grsync
ProcCwd: /home/stefano
ProcEnviron:
 PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
 LANG=it_IT.UTF-8
 SHELL=/bin/bash
Signal: 11
SourcePackage: grsync
StacktraceTop:
 strlen () from /lib/tls/i686/cmov/libc.so.6
 g_strconcat () from /usr/lib/libglib-2.0.so.0
 ?? ()
 ?? ()
 ?? ()
Title: grsync crashed with SIGSEGV in strlen()
Uname: Linux aspire5633 2.6.22-12-generic #1 SMP Sun Sep 23 18:11:30 GMT 2007 i686 GNU/Linux
UserGroups: adm admin audio cdrom dialout dip floppy lpadmin netdev plugdev powerdev scanner video

Revision history for this message
Stefano Karapetsas (stefano-karapetsas) wrote :
Revision history for this message
Apport retracing service (apport) wrote : Symbolic stack trace

StacktraceTop:strlen () from /lib/tls/i686/cmov/libc.so.6
IA__g_strconcat (string1=0x805961f "Grsync: ") at /build/buildd/glib2.0-2.14.1/glib/gstrfuncs.c:253
set_main_title (session=0x11 <Address 0x11 out of bounds>, extra=0x0) at callbacks.c:47
load_settings (main=0x80ca058, session=0x11 <Address 0x11 out of bounds>, filename=0x0)
on_combo_session_changed (combobox=0x80ca058, user_data=0x0) at callbacks.c:843

Revision history for this message
Apport retracing service (apport) wrote : Symbolic threaded stack trace
Revision history for this message
Apport retracing service (apport) wrote : Stack trace with source code
Changed in grsync:
importance: Undecided → Medium
Revision history for this message
Stefano Karapetsas (stefano-karapetsas) wrote : Re: grsynch crashes on save session

In the grsync 0.6-1 source there is only a call to strlen function, in the file callbacks.c at line 454, but this line is commented and replaced with another one without strlen:

453 tmpc = g_strrstr(out, opt);
454 // tmpc = g_strstr_len(out, strlen(out), opt);

also this line is in set_tooltip function, which is called only on windows creation.

Revision history for this message
Mahmoud Kassem (mmkassem) wrote :

The bug is also reproducible under Ubuntu Gusty/7.10 with the Grsync 0.6.1 from http://www.opbyte.it/grsync/
compiled from source with ./configure && make && sudo checkinstall

The crash is due to the load_groups() in the on_session_add_clicked() of callback.c
test: comment the load_groups() call in on_session_add_clicked() and compile,
grsync will not crash but you will have to restart grsync to see the new session/group

Revision history for this message
Mahmoud Kassem (mmkassem) wrote :

correction: callbacks.c not callback.c

Revision history for this message
Mahmoud Kassem (mmkassem) wrote :

I fixed the bug by modifying the original source of Grsync 0.6.1 from http://www.opbyte.it/grsync/

in callbacks.c function: void on_session_add_click

add:
session_last = -1;
before line 895: load_groups((GtkWidget*) button, newses);

This modification fix the bug (does not crash grsync), however might not be the best fix.

Grsync 0.6.1 fixes a number of bugs in the previous version, please check http://www.opbyte.it/grsync/changes.txt
So, I think it is better to patch 0.6.1 and upgrade to 0.6.1 instead of patching 0.6.0

Changed in grsync:
status: New → Confirmed
Revision history for this message
In , Reindl (reindl-redhat-bugs) wrote :

Description of problem:

Open grsync, enter source/destination and "add"
After typing a name the application crashs
The session will be saved, but you have to start grsync again

dmesg says: grsync[6574]: segfault at 00000069 eip 00bdc12b esp bfdc3d8c error 4

Version-Release number of selected component (if applicable):
[root@nb-rhsoft:~]$ rpm -qa | grep grsync
grsync-0.6-1.fc8

BTW:
Thank you for taking it in official repo so i must not build from source every
update

Revision history for this message
In , Sebastian (sebastian-redhat-bugs) wrote :

Confirmed.

I'm no programmer so I cannot say what's going wrong here. I've created some
backtraces and filed a bug upstream:
http://opbyte.freeforums.org/viewtopic.php?p=311#311

FYI: I've missed to push grsync-0.6.1 for F7/F8. But this version is also
crashing. If you want to try it yourself, download it directly from koji:
http://koji.fedoraproject.org/koji/buildinfo?buildID=32209
I'll not push this update before the bug is fixed.

Revision history for this message
In , Mahmoud (mahmoud-redhat-bugs) wrote :

please check this bug report, it has a fix:
https://bugs.launchpad.net/ubuntu/+source/grsync/+bug/148272

Changed in grsync:
status: Unknown → In Progress
Revision history for this message
In , Sebastian (sebastian-redhat-bugs) wrote :

(In reply to comment #2)
> please check this bug report, it has a fix:
> https://bugs.launchpad.net/ubuntu/+source/grsync/+bug/148272

Thanks for the pointer. I included the fix in a scratchbuild:
http://koji.fedoraproject.org/koji/taskinfo?taskID=385048

It's working here, but also please test it Reindl Harald. If it's running, I
will push new packages to rawhide and then to f8/7.

Changed in grsync:
status: In Progress → Incomplete
Revision history for this message
In , Reindl (reindl-redhat-bugs) wrote :

Yes i can confirm the fix
Thank you!

Changed in grsync:
status: Incomplete → In Progress
Revision history for this message
In , Fedora (fedora-redhat-bugs) wrote :

grsync-0.6.1-2.fc8 has been submitted as an update for Fedora 8

Revision history for this message
In , Fedora (fedora-redhat-bugs) wrote :

grsync-0.6.1-2.fc8 has been pushed to the Fedora 8 testing repository. If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with
 su -c 'yum --enablerepo=updates-testing update grsync'. You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F8/FEDORA-2008-1453

Changed in grsync:
status: In Progress → Fix Committed
Revision history for this message
In , Fedora (fedora-redhat-bugs) wrote :

grsync-0.6.1-2.fc8 has been pushed to the Fedora 8 stable repository. If problems still persist, please make note of it in this bug report.

Changed in grsync:
status: Fix Committed → Fix Released
Revision history for this message
Mahmoud Kassem (mmkassem) wrote :

This bug is fixed in the debian package, http://packages.debian.org/sid/grsync
Please upgrade the ubuntu package

Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote :

Marking as fixed, as intrepid currently has the same version as debian unstable.

Changed in grsync:
status: Confirmed → Fix Released
Changed in grsync (Fedora):
importance: Unknown → Low
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.