Launchpad has imported 19 comments from the remote bug at
https://bugzilla.redhat.com/show_bug.cgi?id=698532.

If you reply to an imported comment from within Launchpad, your comment
will be sent to the remote bug automatically. Read more about
Launchpad's inter-bugtracker facilities at
https://help.launchpad.net/InterBugTracking.

------------------------------------------------------------------------
On 2011-04-21T07:20:54+00:00 Steven wrote:

Description of problem:
A "Segmentation fault (core dumped)" is shown when running jfbterm in 
framebuffer mode.

Version-Release number of selected component (if applicable):
Both jfbterm-0.4.7-22 and jfbterm-0.4.7-24

How reproducible:
On i686 version of Fedora 14:
[fc14]~>uname -r
2.6.35.12-88.fc14.i686.PAE
[fc14]~>rpm -q jfbterm
jfbterm-0.4.7-22.fc12.i686


Steps to Reproduce:
1. Boot Fedora 14, and in the boot menu, add the boot parameter "vga=788"
2. As root, run: "chvt 1"
3. Install program "screen" by: "yum install screen"
4. Enter screen by running "screen"
5. jfbterm -e ls
  
Actual results:
A "Segmentation fault (core dumped)" will be shown in the end.

If jfbterm is run run in screen, it will hang and won't back to command
line prompt.

I also tried to recompile
http://mirrors.kernel.org/fedora/development/15/source/SRPMS/jfbterm-0.4.7-24.fc15.src.rpm
on Fedora 14, and run it. Same results.


Expected results:
Back to command line prompt without segfault.

Additional info:

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/4

------------------------------------------------------------------------
On 2011-04-21T07:26:35+00:00 Steven wrote:

BTW, the above testing was run on a virtual machine of VMware workstation.
I also tried the same steps on a real machine running Fedora 14:
CPU: Intel(R) Pentium(R) 4 CPU 2.60GHz
VGA card: Intel Corporation 82865G Integrated Graphics Controller (rev 02)
This issue is reproducible.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/5

------------------------------------------------------------------------
On 2011-04-21T07:30:00+00:00 Steven wrote:

Oops.. 
"If jfbterm is run run in screen, it will hang and won't back to command line
prompt." -> I mean: 
"If jfbterm is _not_ run in screen, it will hang and won't back to command line
prompt."

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/6

------------------------------------------------------------------------
On 2011-04-26T05:09:25+00:00 Steven wrote:

Created attachment 494812
Patch to fix this segfault on exit

This patch was created by Thomas Tsai. After this patch was applied, the
issue has gone.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/7

------------------------------------------------------------------------
On 2011-04-26T13:18:34+00:00 Mamoru wrote:

The attached patch looks good from a quick glance, however
as I cannot reproduce the issue for now I cannot judge if the
patch should really be applied or I cannot judge if this
issue (if exists) is a bug on jfbterm side.

Would you attach a backtrace from gdm for this issue if possible?

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/9

------------------------------------------------------------------------
On 2011-04-26T13:36:10+00:00 Mamoru wrote:

(In reply to comment #4)
> 
> Would you attach a backtrace from gdm for this issue if possible?

s/gdm/gdb

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/10

------------------------------------------------------------------------
On 2011-04-27T08:22:37+00:00 Thomas wrote:

Created attachment 495144
gdb and new patch for tterm_reset_utmp function

Hello,

I think the segfault is happening with incorrect ut_id value. I tried to
fix ut_id, but it works not well especially on Debian for some unknown
reason. After some test, I also found some ut_id is empty, so the new
patch replace ut_id with ut_line and therefore return code checking is
not necessary. Just in caes, we still keep it.

I attached segfault log, new patch and fixed log. There is utmp
structure value dump from gdb, just compare utmp and utp to confirm the
bug issue.

BR, Thomas.

---- summary of error log dump ----
(gdb) p utmp
$1 = {ut_type = 7, ut_pid = 0, ut_line = '\000' <repeats 31 times>, ut_i
d = "\000\000\000",
  ut_user = '\000' <repeats 31 times>, ut_host = '\000' <repeats 255 times>, 
ut_exit = {
    e_termination = 0, e_exit = 0}, ut_session = 0, ut_tv = {tv_sec = 0, 
tv_usec = 0},
  ut_addr_v6 = {0, 0, 0, 0}, __unused = '\000' <repeats 19 times>}
(gdb) p *utp
Cannot access memory at address 0x0
(gdb) c
Continuing.

Program received signal SIGSEGV, Segmentation fault.
tterm_reset_utmp (p=<value optimized out>) at term.c:309
---- done ----

--- after new patch ----
(gdb) p utmp
$1 = {ut_type = 7, ut_pid = 0, ut_line = "pts/3", '\000' <repeats 26 times>,
  ut_id = "\000\000\000", ut_user = '\000' <repeats 31 times>,
  ut_host = '\000' <repeats 255 times>, ut_exit = {e_termination = 0, e_exit = 
0}, ut_session = 0,
  ut_tv = {tv_sec = 0, tv_usec = 0}, ut_addr_v6 = {0, 0, 0, 0},
  __unused = '\000' <repeats 19 times>}
(gdb) p *utp
$2 = {ut_type = 7, ut_pid = 3842, ut_line = "pts/3", '\000' <repeats 26 times>,
  ut_id = "\000\000\000", ut_user = "root", '\000' <repeats 27 times>,
  ut_host = '\000' <repeats 255 times>, ut_exit = {e_termination = 0, e_exit = 
0}, ut_session = 0,
  ut_tv = {tv_sec = 1303916197, tv_usec = 0}, ut_addr_v6 = {0, 0, 0, 0},
  __unused = '\000' <repeats 19 times>}
(gdb) c
Continuing.

Breakpoint 1, tterm_reset_utmp (p=0x8058c40) at term.c:298
298     {
(gdb) c
Continuing.

Program exited normally.
---- done ----

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/11

------------------------------------------------------------------------
On 2011-04-28T17:01:18+00:00 Mamoru wrote:

Well, now I am trying slowly to understand what tterm_reset_utmp() in
term.c is doing, however, $ man getutid says:

    If ut->ut_type is one of INIT_PROCESS, LOGIN_PROCESS, 
    USER_PROCESS, or DEAD_PROCESS, getutid() will find the 
    first entry  whose  ut_id  field matches ut->ut_id.

So changing strncpy(utmp.ut_id, tn, sizeof(utmp.ut_id)); to
strncpy(utmp.ut_line, tn, sizeof(utmp.ut_line)); before calling 
utp = getutid(&utmp); seems wrong to me: As memset is called beforehand, after 
your patch is applied utmp.ut_id will be "\0" when getutid(&utmp) is called, 
and utp will be always NULL (perhaps).

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/12

------------------------------------------------------------------------
On 2011-04-29T03:04:11+00:00 Mamoru wrote:

Thomas, if possible would you dump the contents of TTerm* p on
tterm_reset_utmp when this issue happens (especially p->name)?

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/13

------------------------------------------------------------------------
On 2011-04-29T08:26:03+00:00 Thomas wrote:

Hello,

The TTerm values dump here:
$3 = (TTerm *) 0x8058c40
(gdb) p *p
$4 = {ptyfd = 9, ttyfd = 10, name = "/dev/pts/2", '\000' <repeats 53 times>, 
,.......(skip)
(gdb) p p->name
$5 = "/dev/pts/2", '\000' <repeats 53 times>

The correct ut_id should be '/2', and 'rindex(...)+4' may get incorrect ut_id.
We could still try to back to fix ut_id, or replace getutid(&utmp) with 
getutline(&utmp).

If you need more information, I am happy to dump it for you.
Thank You.

BR, Thomas.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/14

------------------------------------------------------------------------
On 2011-04-29T19:20:23+00:00 Mamoru wrote:

Okay, thank you for followups. I will submit possible fix for this issue
soon. I would appreciate it if you would try the new rpms which may fix
this issue.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/15

------------------------------------------------------------------------
On 2011-04-29T19:22:33+00:00 Fedora wrote:

jfbterm-0.4.7-25.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/jfbterm-0.4.7-25.fc15

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/16

------------------------------------------------------------------------
On 2011-04-29T19:23:12+00:00 Fedora wrote:

jfbterm-0.4.7-25.fc14 has been submitted as an update for Fedora 14.
https://admin.fedoraproject.org/updates/jfbterm-0.4.7-25.fc14

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/17

------------------------------------------------------------------------
On 2011-04-29T19:23:40+00:00 Fedora wrote:

jfbterm-0.4.7-25.fc13 has been submitted as an update for Fedora 13.
https://admin.fedoraproject.org/updates/jfbterm-0.4.7-25.fc13

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/18

------------------------------------------------------------------------
On 2011-04-30T00:27:39+00:00 Steven wrote:

I confirmed that this patch fixes the issue.
I have downloaded 
http://kojipkgs.fedoraproject.org/packages/jfbterm/0.4.7/25.fc14/i686/jfbterm-0.4.7-25.fc14.i686.rpm
and install it on an i686 Fedora 14 machine. After that, no segfault issue when 
jfbterm exists.
Cool!
BTW, do you know anyone in the upstream:
http://sourceforge.jp/projects/jfbterm/memberlist
?
Is that possible all the patches in Fedora can be mergered by the upstream 
project and have another release (e.g. 0.4.8)? 
Thanks.

Steven.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/19

------------------------------------------------------------------------
On 2011-04-30T23:20:23+00:00 Fedora wrote:

Package jfbterm-0.4.7-25.fc14:
* should fix your issue,
* was pushed to the Fedora 14 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing jfbterm-0.4.7-25.fc14'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/jfbterm-0.4.7-25.fc14
then log in and leave karma (feedback).

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/20

------------------------------------------------------------------------
On 2011-05-05T05:07:52+00:00 Fedora wrote:

jfbterm-0.4.7-25.fc15 has been pushed to the Fedora 15 stable
repository.  If problems still persist, please make note of it in this
bug report.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/21

------------------------------------------------------------------------
On 2011-05-09T20:56:43+00:00 Fedora wrote:

jfbterm-0.4.7-25.fc14 has been pushed to the Fedora 14 stable
repository.  If problems still persist, please make note of it in this
bug report.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/22

------------------------------------------------------------------------
On 2011-05-09T20:57:20+00:00 Fedora wrote:

jfbterm-0.4.7-25.fc13 has been pushed to the Fedora 13 stable
repository.  If problems still persist, please make note of it in this
bug report.

Reply at:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/comments/23


** Changed in: jfbterm (Fedora)
       Status: Unknown => Fix Released

** Changed in: jfbterm (Fedora)
   Importance: Unknown => Medium

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/253163

Title:
  segfault of jfbterm in intrepid with uvesafb

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/jfbterm/+bug/253163/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to