* details.
*
* You should have received a copy of the GNU Lesser General Public
- * License along with these librararies and programs; if not, write
+ * License along with these libraries and programs; if not, write
* to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
* Floor, Boston, MA 02110-1301 USA
*/
if (cbs->text->ptr)
{
- strcpy(s, cbs->text->ptr);
+ snprintf(s, sizeof(buffer) - (s - buffer), "%s", cbs->text->ptr);
s += cbs->text->length;
}
else
session_selected = True;
- switch ( (int) client_data) {
+ switch ( (long) client_data) {
case OB_RESTART_SERVER:
CleanupAndExit(NULL, NOTIFY_RESTART);
XmFONTLIST_DEFAULT_TAG));
string = XmStringConcat(xmstr, XmStringSeparatorCreate());
}
+
+ fclose(fp);
}
else
{
/** beginning of main. **/
char buff[128];
if (XmToggleButtonGadgetGetState(w)) {
- strcpy(buff, "LANG=");
- strcat(buff, client);
+ snprintf(buff, sizeof(buff), "LANG=%s", (char *) client);
putenv(buff);
execv(orig_argv[0], orig_argv);
}
* the logo to display in logo_pixmap
**************************************************************************/
void
-SetDtLabelAndIcon()
+SetDtLabelAndIcon(void)
{
static XmString blanks = NULL;
int i;
#ifdef VG_TRACE
vg_TRACE_EXECUTION("main: entered TellRequester ...");
#endif /* VG_TRACE */
- write(1, buf, nbytes);
+ if(-1 == write(1, buf, nbytes)) {
+ perror(strerror(errno));
+ }
}