From: Tom Yu Date: Fri, 4 Aug 1995 05:04:06 +0000 (+0000) Subject: * cleanup.c (pty_cleanup): Add missing declarations for retval and X-Git-Tag: krb5-1.0-beta6~1418 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=efc2799f3408ede20770af24f861f6d1c349fbc9;p=krb5.git * cleanup.c (pty_cleanup): Add missing declarations for retval and fd. Also, align preprocessor directives with left margin. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6406 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/util/pty/ChangeLog b/src/util/pty/ChangeLog index a8aa1cbef..58bb11c3a 100644 --- a/src/util/pty/ChangeLog +++ b/src/util/pty/ChangeLog @@ -1,3 +1,8 @@ +Fri Aug 4 00:59:20 1995 Tom Yu + + * cleanup.c (pty_cleanup): Add missing declarations for retval and + fd. Also, align preprocessor directives with left margin. + Thu Aug 3 15:04:34 1995 Sam Hartman * configure.in: Check for vhangup and killpg. diff --git a/src/util/pty/cleanup.c b/src/util/pty/cleanup.c index c5726bd6f..8d4463b27 100644 --- a/src/util/pty/cleanup.c +++ b/src/util/pty/cleanup.c @@ -29,6 +29,7 @@ long pty_cleanup (slave, pid, update_utmp) int update_utmp; { struct utmp ut; + int retval, fd; #ifndef NO_UT_PID ut.ut_pid = 0; @@ -55,17 +56,18 @@ long pty_cleanup (slave, pid, update_utmp) * along SIGHUP, all processes may not die. */ if ( pid > 0 ) { - #ifdef HAVE_KILLPG +#ifdef HAVE_KILLPG killpg(pid, SIGHUP); - #else +#else kill( -(pid), SIGHUP ); #endif /*HAVE_KILLPG*/ } #else /* HAVE_REVOKE*/ - #ifdef VHANG_LAST +#ifdef VHANG_LAST if ( retval = ( pty_open_ctty( slave, &fd ))) return retval; ptyint_vhangup(); + return 0; #endif #endif }