NSM: Fix uninitialized value error with client labels.

This commit is contained in:
Jonathan Moore Liles 2012-06-16 17:51:02 -07:00
parent 1f9c2bbb6a
commit 553db45e8b
1 changed files with 5 additions and 1 deletions

View File

@ -127,7 +127,10 @@ public:
{ {
if ( _label ) if ( _label )
free( _label ); free( _label );
_label = strdup( l ); if ( l )
_label = strdup( l );
else
_label = NULL;
} }
bool gui_visible ( void ) const bool gui_visible ( void ) const
@ -210,6 +213,7 @@ public:
Client ( ) Client ( )
{ {
_label = 0;
_gui_visible = true; _gui_visible = true;
addr = 0; addr = 0;
_reply_errcode = 0; _reply_errcode = 0;