Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 56670 - ncurses mvgatch() function segfaults
ncurses mvgatch() function segfaults
Product: Red Hat Linux
Classification: Retired
Component: ncurses (Show other bugs)
i386 Linux
medium Severity high
: ---
: ---
Assigned To: Bernhard Rosenkraenzer
Aaron Brown
Depends On:
  Show dependency treegraph
Reported: 2001-11-23 17:26 EST by Rick Richardson
Modified: 2007-04-18 12:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-11-24 16:02:02 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Rick Richardson 2001-11-23 17:26:28 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.78 [en] (X11; U; Linux 2.4.9-13 i686)

Description of problem:

$ rpm -q --whatprovides /usr/lib/libncurses.so

$ cat broke.c
#include <ncurses.h>

        attr_t  attr;

        attr = 0;
        mvchgat(0, 0, 40, attr, 0, NULL);

$ gcc  -g -o broke  broke.c -lm -lncurses
$ ./broke
Segmentation fault

Well, there's the problem, alrlright!

If linked against the libncurses.so that was in RH 7.0, it works fine.

Version-Release number of selected component (if applicable):

How reproducible:
Comment 1 Rick Richardson 2001-11-24 16:01:55 EST
Here's a workaround if you have the luxury of being able to recompile the
application... but it won't fix any applications that are binary-only...

#if 0
        // Busted in RH 7.2
        mvchgat(y, x, wid, attr, 0, NULL);
                int     i;

                for (i = 0; i < wid; ++i)
                        chtype  ch;

                        ch = mvinch(y, x+i);
                        ch &= 0xff;
                        ch |= attr;
                        mvaddch(y, x+i, ch);
Comment 2 Bernhard Rosenkraenzer 2001-11-27 10:12:46 EST
Fixed in 5.2-13
Comment 3 Rick Richardson 2001-11-27 12:21:05 EST
I am confused.  This library is fundamental to the proper operation of Curses
Why isn't the fix being made available to all Redhat 7.2 users via Update
Agent?  Is it
Redhat's intent that binary applications must be statically linked with a
working ncurses,
rather than with the broken dynamic library supplied in RH 7.2?

Note You need to log in before you can comment on or make changes to this bug.