X-Git-Url: http://andersk.mit.edu/gitweb/moira.git/blobdiff_plain/7bd50861a24d8f7b8635b3c9f90028f3e3635f7b..4556f559685e6d7a97f07a17eacbe3d144b833db:/update/client.c diff --git a/update/client.c b/update/client.c index e34f355e..6e48a0e1 100644 --- a/update/client.c +++ b/update/client.c @@ -10,7 +10,9 @@ static char *rcsid_client2_c = "$Header$"; /* * MODULE IDENTIFICATION: * $Header$ - * Copyright 1987 MIT Project Athena. + * Copyright 1987, 1988 by the Massachusetts Institute of Technology. + * For copying and distribution information, please see the file + * . * DESCRIPTION: * This code handles the actual distribution of data files * to servers in the SMS server-update program. @@ -22,6 +24,7 @@ static char *rcsid_client2_c = "$Header$"; * sms_update_server */ +#include #include #include #include @@ -34,7 +37,7 @@ static char *rcsid_client2_c = "$Header$"; #include extern char *malloc(); -extern int errno; +extern int errno, dbg; static char buf[BUFSIZ]; static int code; @@ -53,7 +56,7 @@ CONNECTION conn; * RETURN VALUE: * void * SIDE EFFECTS: - * Initializes GDB library and SMSU error table. + * Initializes GDB library. * PROBLEMS: * */ @@ -64,7 +67,6 @@ initialize() if (!initialized) { gdb_init(); - init_smsU_err_tbl(); initialized++; } } @@ -234,7 +236,7 @@ static execute(path) char *path; { - union wait response; + int response; STRING data; register int code; @@ -246,15 +248,10 @@ execute(path) code = receive_object(conn, (char *)&response, INTEGER_T); if (code) return(connection_errno(conn)); - if (response.w_retcode) { -/**************************************************************** - * The following line is there because the current update servers - * don't return the correct error code when an update fails. Remove - * this line when they are fixed. -mar 7/26/88 - ****************************************************************/ - return(SMS_INTERNAL); - return(response.w_retcode); - } + if (dbg & DBG_TRACE) + com_err(whoami, response, "execute returned %d", response); + if (response) + return(response); return(SMS_SUCCESS); }