diff options
author | hobbs <hobbs> | 2001-10-16 21:13:50 (GMT) |
---|---|---|
committer | hobbs <hobbs> | 2001-10-16 21:13:50 (GMT) |
commit | 09c2d5f838c1c7b9249771e301936f7fc71ca5dd (patch) | |
tree | 63eedae95ae0070120a21cccb6fb58524cf31abb | |
parent | a6aca92723218392fb1a725dbe9fdbe5e9f4bd86 (diff) | |
download | tcl-09c2d5f838c1c7b9249771e301936f7fc71ca5dd.zip tcl-09c2d5f838c1c7b9249771e301936f7fc71ca5dd.tar.gz tcl-09c2d5f838c1c7b9249771e301936f7fc71ca5dd.tar.bz2 |
* unix/tclLoadAout.c (TclGuessPackageName): removed unused vars
and fixed warnings. [Bug #446622] (lim)
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | unix/tclLoadAout.c | 12 |
2 files changed, 13 insertions, 4 deletions
@@ -1,3 +1,8 @@ +2001-10-16 Jeff Hobbs <jeffh@ActiveState.com> + + * unix/tclLoadAout.c (TclGuessPackageName): removed unused vars + and fixed warnings. [Bug #446622] (lim) + 2001-10-15 Miguel Sofer <msofer@users.sourceforge.net> * generic/tclProc.c: changing a memcmp to strncmp to avoid a memory diff --git a/unix/tclLoadAout.c b/unix/tclLoadAout.c index 4e6a196..e78158d 100644 --- a/unix/tclLoadAout.c +++ b/unix/tclLoadAout.c @@ -14,7 +14,7 @@ * and Design Engineering (MADE) Initiative through ARPA contract * F33615-94-C-4400. * - * RCS: @(#) $Id: tclLoadAout.c,v 1.7 2001/09/28 01:21:53 dgp Exp $ + * RCS: @(#) $Id: tclLoadAout.c,v 1.8 2001/10/16 21:13:50 hobbs Exp $ */ #include "tclInt.h" @@ -22,6 +22,11 @@ #ifdef HAVE_EXEC_AOUT_H # include <sys/exec_aout.h> #endif +#ifdef HAVE_UNISTD_H +# include <unistd.h> +#else +# include "../compat/unistd.h" +#endif /* * Some systems describe the a.out header in sys/exec.h, and some in @@ -336,7 +341,7 @@ FindLibraries (interp, fileName, buf) Tcl_DString * buf; /* Buffer where the -l an -L flags */ { FILE * f; /* The load module */ - int c; /* Byte from the load module */ + int c = 0; /* Byte from the load module */ char * p; Tcl_DString ds; CONST char *native; @@ -475,9 +480,8 @@ TclGuessPackageName(fileName, bufPtr) * package name to this if possible. */ { char *p, *q, *r; - int srcOff, dstOff; - if (q = strrchr(fileName,'/')) { + if ((q = strrchr(fileName,'/'))) { q++; } else { q = fileName; |