--- nfs-server-2.2beta29/logging.c.fix Thu Aug 27 20:38:54 1998 +++ nfs-server-2.2beta29/logging.c Thu Aug 27 20:41:21 1998 @@ -123,7 +123,7 @@ va_start(args); #endif #ifdef HAVE_VPRINTF - vsprintf(buff, fmt, args); + vsnprintf(buff, sizeof(buff), fmt, args); #else /* Figure out how to use _doprnt here. */ #endif @@ -166,7 +166,7 @@ return; sp = buff; - sprintf(sp, "%s [%d ", xname, rqstp->rq_cred.oa_flavor); + snprintf(sp, sizeof(sp), "%s [%d ", xname, rqstp->rq_cred.oa_flavor); sp += strlen(sp); if (rqstp->rq_cred.oa_flavor == AUTH_UNIX) { struct authunix_parms *unix_cred; @@ -174,7 +174,7 @@ unix_cred = (struct authunix_parms *) rqstp->rq_clntcred; tm = localtime(&unix_cred->aup_time); - sprintf(sp, "%d/%d/%d %02d:%02d:%02d %s %d.%d", + snprintf(sp, sizeof(sp), "%d/%d/%d %02d:%02d:%02d %s %d.%d", tm->tm_year, tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min, tm->tm_sec, unix_cred->aup_machname,