Hello community,
here is the log from the commit of package yast2-ncurses
checked in at Thu Sep 25 01:01:01 CEST 2008.
--------
--- yast2-ncurses/yast2-ncurses.changes 2008-09-12 16:47:39.000000000 +0200
+++ /mounts/work_src_done/STABLE/yast2-ncurses/yast2-ncurses.changes 2008-09-24 18:36:23.084854000 +0200
@@ -1,0 +2,21 @@
+Wed Sep 24 18:35:03 CEST 2008 - sh@suse.de
+
+- Require latest libyui (API change!)
+- V 2.17.9
+
+-------------------------------------------------------------------
+Fri Sep 19 15:43:12 CEST 2008 - sh@suse.de
+
+- Fixed bnc #427370: Segfault in NCFrame called from Python
+- Fixed a dozen other similar hazardous pointer uses
+- Applied Werner's bce patch (now in SVN) (bnc #423615)
+- Fixed bnc #427372: Segfault in empty NCTable
+- V 2.17.8
+
+-------------------------------------------------------------------
+Wed Sep 17 15:25:00 CEST 2008 - werner@suse.de
+
+- Add workaround for bce problem, this could be caused by the
+ old c++ ncurses interface used in yast2-ncurses (bnc#423615)
+
+-------------------------------------------------------------------
Old:
----
yast2-ncurses-2.17.7.tar.bz2
New:
----
yast2-ncurses-2.17.9.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-ncurses.spec ++++++
--- /var/tmp/diff_new_pack.C11776/_old 2008-09-25 01:00:44.000000000 +0200
+++ /var/tmp/diff_new_pack.C11776/_new 2008-09-25 01:00:44.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-ncurses (Version 2.17.7)
+# spec file for package yast2-ncurses (Version 2.17.9)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -19,20 +19,20 @@
Name: yast2-ncurses
-Version: 2.17.7
+Version: 2.17.9
Release: 1
License: GPL v2 or later
Group: System/YaST
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-ncurses-2.17.7.tar.bz2
+Source0: yast2-ncurses-2.17.9.tar.bz2
Prefix: /usr
BuildRequires: dejagnu doxygen gcc-c++ yast2-devtools
BuildRequires: blocxx-devel libxcrypt-devel ncurses-devel
Summary: YaST2 - Character Based User Interface
Provides: yast2_ui
Requires: glibc-locale
-BuildRequires: yast2-libyui-devel >= 2.17.10
-Requires: yast2-libyui >= 2.17.10
+BuildRequires: yast2-libyui-devel >= 2.17.11
+Requires: yast2-libyui >= 2.17.11
Recommends: yast2-ncurses-pkg
%description
@@ -56,7 +56,7 @@
%prep
-%setup -n yast2-ncurses-2.17.7
+%setup -n yast2-ncurses-2.17.9
%build
%{prefix}/bin/y2tool y2autoconf
@@ -93,6 +93,18 @@
%{prefix}/include/YaST2/ncurses/
%doc %{prefix}/share/doc/packages/yast2-ncurses
%changelog
+* Wed Sep 24 2008 sh@suse.de
+- Require latest libyui (API change!)
+- V 2.17.9
+* Fri Sep 19 2008 sh@suse.de
+- Fixed bnc #427370: Segfault in NCFrame called from Python
+- Fixed a dozen other similar hazardous pointer uses
+- Applied Werner's bce patch (now in SVN) (bnc #423615)
+- Fixed bnc #427372: Segfault in empty NCTable
+- V 2.17.8
+* Wed Sep 17 2008 werner@suse.de
+- Add workaround for bce problem, this could be caused by the
+ old c++ ncurses interface used in yast2-ncurses (bnc#423615)
* Fri Sep 12 2008 sh@suse.de
- Require latest libyui
- V 2.17.7
++++++ yast2-ncurses-2.17.7.tar.bz2 -> yast2-ncurses-2.17.9.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/NCCheckBoxFrame.cc new/yast2-ncurses-2.17.9/src/NCCheckBoxFrame.cc
--- old/yast2-ncurses-2.17.7/src/NCCheckBoxFrame.cc 2008-06-11 16:38:45.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/NCCheckBoxFrame.cc 2008-09-19 15:32:12.000000000 +0200
@@ -52,7 +52,7 @@
int NCCheckBoxFrame::preferredWidth()
{
- defsze.W = firstChild()->preferredWidth();
+ defsze.W = hasChildren() ? firstChild()->preferredWidth() : 0;
if ( label.width() > ( unsigned )defsze.W )
defsze.W = label.width();
@@ -65,7 +65,8 @@
int NCCheckBoxFrame::preferredHeight()
{
- defsze.H = firstChild()->preferredHeight() + framedim.Sze.H;
+ defsze.H = hasChildren() ? firstChild()->preferredHeight() : 0;
+ defsze.H += framedim.Sze.H;
return defsze.H;
}
@@ -76,7 +77,9 @@
wsze csze( newheight, newwidth );
wRelocate( wpos( 0 ), csze );
csze = wsze::max( 0, csze - framedim.Sze );
- firstChild()->setSize( csze.W, csze.H );
+
+ if ( hasChildren() )
+ firstChild()->setSize( csze.W, csze.H );
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/NCDialog.cc new/yast2-ncurses-2.17.9/src/NCDialog.cc
--- old/yast2-ncurses-2.17.7/src/NCDialog.cc 2008-06-11 16:37:16.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/NCDialog.cc 2008-09-19 15:37:48.000000000 +0200
@@ -168,11 +168,15 @@
if ( dialogType() == YMainDialog || ! hasChildren() )
return wGetDefsze().W;
- wsze csze( firstChild()->preferredHeight(),
- firstChild()->preferredWidth() );
-
- csze = wsze::min( wGetDefsze(),
- wsze::max( csze, wsze( 1 ) ) );
+ wsze csze( 0, 0 );
+
+ if ( hasChildren() )
+ {
+ csze = wsze( firstChild()->preferredHeight(),
+ firstChild()->preferredWidth() );
+ }
+
+ csze = wsze::min( wGetDefsze(), wsze::max( csze, wsze( 1 ) ) );
return csze.W;
}
@@ -185,9 +189,14 @@
return wGetDefsze().H;
}
- wsze csze( firstChild()->preferredHeight(),
-
- firstChild()->preferredWidth() );
+ wsze csze( 0, 0 );
+
+ if ( hasChildren() )
+ {
+ csze = wsze( firstChild()->preferredHeight(),
+ firstChild()->preferredWidth() );
+ }
+
csze = wsze::min( wGetDefsze(),
wsze::max( csze, wsze( 1 ) ) );
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/NCDumbTab.cc new/yast2-ncurses-2.17.9/src/NCDumbTab.cc
--- old/yast2-ncurses-2.17.7/src/NCDumbTab.cc 2008-08-22 18:43:16.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/NCDumbTab.cc 2008-09-19 15:34:36.000000000 +0200
@@ -43,7 +43,7 @@
int NCDumbTab::preferredWidth()
{
- defsze.W = firstChild()->preferredWidth();
+ defsze.W = hasChildren() ? firstChild()->preferredWidth() : 0;
YItemIterator listIt = itemsBegin();
@@ -72,7 +72,8 @@
int NCDumbTab::preferredHeight()
{
- defsze.H = firstChild()->preferredHeight() + framedim.Sze.H;
+ defsze.H = hasChildren() ? firstChild()->preferredHeight() : 0;
+ defsze.H += framedim.Sze.H;
return defsze.H;
}
@@ -273,11 +274,12 @@
if ( firstChild() )
{
- NCWidget * child = dynamic_cast(firstChild());
+ NCWidget * child = dynamic_cast( firstChild() );
+
if ( child )
child->Redraw();
- redrawChilds( firstChild() );
+ redrawChild( firstChild() );
}
}
@@ -305,7 +307,7 @@
return ret;
}
-void NCDumbTab::redrawChilds( YWidget *widget )
+void NCDumbTab::redrawChild( YWidget *widget )
{
NCWidget * child;
@@ -317,7 +319,7 @@
child = dynamic_cast(*widgetIt);
if ( child )
child->Redraw();
- redrawChilds( *widgetIt );
+ redrawChild( *widgetIt );
++widgetIt;
}
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/NCDumbTab.h new/yast2-ncurses-2.17.9/src/NCDumbTab.h
--- old/yast2-ncurses-2.17.7/src/NCDumbTab.h 2008-07-16 12:28:25.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/NCDumbTab.h 2008-09-19 15:34:45.000000000 +0200
@@ -42,7 +42,7 @@
virtual const char * location() const { return "NCDumbTab"; }
virtual void wRedraw();
- void redrawChilds( YWidget *widget );
+ void redrawChild( YWidget *widget );
public:
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/NCFrame.cc new/yast2-ncurses-2.17.9/src/NCFrame.cc
--- old/yast2-ncurses-2.17.7/src/NCFrame.cc 2008-06-11 16:12:04.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/NCFrame.cc 2008-09-19 15:37:17.000000000 +0200
@@ -43,7 +43,7 @@
int NCFrame::preferredWidth()
{
- defsze.W = firstChild()->preferredWidth();
+ defsze.W = hasChildren() ? firstChild()->preferredWidth() : 0;
if ( label.width() > ( unsigned )defsze.W )
defsze.W = label.width();
@@ -56,7 +56,8 @@
int NCFrame::preferredHeight()
{
- defsze.H = firstChild()->preferredHeight() + framedim.Sze.H;
+ defsze.H = hasChildren() ? firstChild()->preferredHeight() : 0;
+ defsze.H += framedim.Sze.H;
return defsze.H;
}
@@ -67,7 +68,9 @@
wsze csze( newheight, newwidth );
wRelocate( wpos( 0 ), csze );
csze = wsze::max( 0, csze - framedim.Sze );
- firstChild()->setSize( csze.W, csze.H );
+
+ if ( hasChildren() )
+ firstChild()->setSize( csze.W, csze.H );
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/NCTable.cc new/yast2-ncurses-2.17.9/src/NCTable.cc
--- old/yast2-ncurses-2.17.7/src/NCTable.cc 2008-08-22 18:43:16.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/NCTable.cc 2008-09-19 16:12:25.000000000 +0200
@@ -289,6 +289,9 @@
void NCTable::selectItem( YItem *yitem, bool selected )
{
+ if ( ! yitem )
+ return;
+
YTableItem *item = dynamic_cast( yitem );
YUI_CHECK_PTR( item );
@@ -507,5 +510,4 @@
{
selectItem( it, !( it->selected() ) );
}
-
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/ncursesp.cc new/yast2-ncurses-2.17.9/src/ncursesp.cc
--- old/yast2-ncurses-2.17.7/src/ncursesp.cc 2008-06-10 16:11:09.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/ncursesp.cc 2008-09-19 15:52:37.000000000 +0200
@@ -109,7 +109,7 @@
NCursesPanel::refresh()
{
::update_panels();
- return doupdate();
+ return ::doupdate();
}
int
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/ncursesp.h new/yast2-ncurses-2.17.9/src/ncursesp.h
--- old/yast2-ncurses-2.17.7/src/ncursesp.h 2008-06-10 16:11:10.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/ncursesp.h 2008-09-19 15:52:37.000000000 +0200
@@ -22,8 +22,8 @@
#include <iosfwd>
#include "ncursesw.h"
-#include "etip.h"
-#include
+#include
+#include
class NCursesPanel : public NCursesWindow
@@ -114,7 +114,7 @@
int cols,
int begin_y = 0,
int begin_x = 0 )
- : NCursesWindow( lines, cols, begin_y, begin_x )
+ : NCursesWindow( lines, cols, begin_y, begin_x ), p(0)
{
init();
}
@@ -123,7 +123,7 @@
* This constructor creates the default Panel associated with the
* ::stdscr window
*/
- NCursesPanel() : NCursesWindow( ::stdscr ) { init(); }
+ NCursesPanel() : NCursesWindow( ::stdscr ), p(0) { init(); }
virtual ~NCursesPanel();
@@ -235,12 +235,12 @@
* Propagate all panel changes to the virtual screen and update the
* physical screen.
*/
- int refresh();
+ virtual int refresh();
/**
* Propagate all panel changes to the virtual screen.
*/
- int noutrefresh();
+ virtual int noutrefresh();
/**
* Redraw all panels.
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/ncursesw.cc new/yast2-ncurses-2.17.9/src/ncursesw.cc
--- old/yast2-ncurses-2.17.7/src/ncursesw.cc 2008-06-10 16:11:08.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/ncursesw.cc 2008-09-19 15:52:37.000000000 +0200
@@ -39,6 +39,11 @@
*/
#include <iostream>
+#include
+#include
+#include
+#undef line
+#undef columns
#define YUILogComponent "ncurses"
#include
@@ -193,6 +198,11 @@
void
NCursesWindow::init( void )
{
+ static char * env;
+ if (!env && (env = ::getenv("TERM"))) {
+ if (::strncmp(env, "linux", 5) == 0)
+ back_color_erase = FALSE;
+ }
leaveok( 0 );
keypad( 1 );
meta( 1 );
@@ -225,22 +235,20 @@
}
NCursesWindow::NCursesWindow()
+ : w(0), alloced(FALSE), par(0), subwins(0), sib(0)
{
if ( !b_initialized )
initialize();
- w = ( WINDOW * )0;
+ w = static_cast(0);
init();
- alloced = FALSE;
-
- subwins = par = sib = 0;
-
count++;
}
NCursesWindow::NCursesWindow( int lines, int cols, int begin_y, int begin_x )
+ : w(0), alloced(TRUE), par(0), subwins(0), sib(0)
{
if ( !b_initialized )
initialize();
@@ -268,29 +276,25 @@
init();
- alloced = TRUE;
- subwins = par = sib = 0;
count++;
}
NCursesWindow::NCursesWindow( WINDOW* &window )
+ : w(0), alloced(FALSE), par(0), subwins(0), sib(0)
{
if ( !b_initialized )
initialize();
- w = window;
+ w = window ? window : ::stdscr;
init();
- alloced = FALSE;
-
- subwins = par = sib = 0;
-
count++;
}
NCursesWindow::NCursesWindow( NCursesWindow& win, int l, int c,
int begin_y, int begin_x, char absrel )
+ : w(0), alloced(TRUE), par(0), subwins(0), sib(0)
{
if ( l <= 0 )
l = 1;
@@ -336,10 +340,6 @@
win.subwins = this;
- subwins = 0;
-
- alloced = TRUE;
-
count++;
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/src/ncursesw.h new/yast2-ncurses-2.17.9/src/ncursesw.h
--- old/yast2-ncurses-2.17.7/src/ncursesw.h 2008-06-10 16:11:09.000000000 +0200
+++ new/yast2-ncurses-2.17.9/src/ncursesw.h 2008-09-19 15:52:37.000000000 +0200
@@ -21,13 +21,12 @@
#include <iosfwd>
-#include
+#include
#include <cstdio>
#include <cstdarg>
#include "position.h"
-#include
-
+#include
/* SCO 3.2v4 curses.h includes term.h, which defines lines as a macro.
Undefine it here, because NCursesWindow uses lines as a method. */
@@ -1030,17 +1029,17 @@
/**
* Number of lines on terminal, *not* window
*/
- static int lines() { return LINES; }
+ static int lines() { initialize(); return LINES; }
/**
* Number of cols on terminal, *not* window
*/
- static int cols() { return COLS; }
+ static int cols() { initialize(); return COLS; }
/**
* Size of a tab on terminal, *not* window
*/
- static int tabsize() { return TABSIZE; }
+ static int tabsize() { initialize(); return TABSIZE; }
/**
* Number of available colors
@@ -1068,22 +1067,22 @@
/**
* Column of top left corner relative to stdscr
*/
- int begx() const { return w->_begx; }
+ int begx() const { return getbegx(w); }
/**
* Line of top left corner relative to stdscr
*/
- int begy() const { return w->_begy; }
+ int begy() const { return getbegy(w); }
/**
* Largest x coord in window
*/
- int maxx() const { return w->_maxx; }
+ int maxx() const { return getmaxx(w) == ERR ? ERR : getmaxx(w)-1; }
/**
* Largest y coord in window
*/
- int maxy() const { return w->_maxy; }
+ int maxy() const { return getmaxy(w) == ERR ? ERR : getmaxy(w)-1; }
wsze size() const { return wsze( height(), width() ); }
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.17.7/VERSION new/yast2-ncurses-2.17.9/VERSION
--- old/yast2-ncurses-2.17.7/VERSION 2008-09-12 16:47:06.000000000 +0200
+++ new/yast2-ncurses-2.17.9/VERSION 2008-09-24 18:34:59.000000000 +0200
@@ -1 +1 @@
-2.17.7
+2.17.9
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org