On Wednesday 13 August 2003 15:43, Dave Serls wrote:
>   My hack was:
> >     case BScreen::Exit:
> >
> >     if (item->exec()) {
> >       int retc;
> >       retc = system(item->exec());
> >       if ( retc != 0 ) {
> >          char  nxmsg[128];
> >          strcpy( nxmsg, "xmessage " );
> >          strcat( nxmsg, item->exec() );
> >          strcat( nxmsg, " disallowed session exit." );
> >          bexec( nxmsg, getScreen()->displayString() );
> >          break;
> >       }
> >     }
>

not too shabby.  Let's C++'ify it to get rid of that buffer.

std::string msg = "xmessage ";
msg += item->exec();
msg += " disallowed session exit.";


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
List archives:  http://asgardsrealm.net/lurker/splash/index.html
Trouble? Contact [EMAIL PROTECTED]

Reply via email to