Revision: 41162
          http://brlcad.svn.sourceforge.net/brlcad/?rev=41162&view=rev
Author:   brlcad
Date:     2010-10-29 06:09:12 +0000 (Fri, 29 Oct 2010)

Log Message:
-----------
enable and quell all strict verbose compilation warnings.  make interp global 
be INTERP to make it clear where the gobal is being used.  mark unused params.

Modified Paths:
--------------
    brlcad/trunk/src/bwish/Makefile.am
    brlcad/trunk/src/bwish/cmd.c
    brlcad/trunk/src/bwish/input.c
    brlcad/trunk/src/bwish/main.c

Modified: brlcad/trunk/src/bwish/Makefile.am
===================================================================
--- brlcad/trunk/src/bwish/Makefile.am  2010-10-29 06:02:15 UTC (rev 41161)
+++ brlcad/trunk/src/bwish/Makefile.am  2010-10-29 06:09:12 UTC (rev 41162)
@@ -29,6 +29,7 @@
 endif
 
 bwish_CFLAGS = \
+       ${STRICT_FLAGS} \
        -DBWISH=1 \
        ${X_CFLAGS} \
        ${ITCL_CPPFLAGS} \
@@ -54,6 +55,7 @@
 endif
 
 btclsh_CFLAGS = \
+       ${STRICT_FLAGS} \
        ${ITCL_CPPFLAGS} \
        ${TCL_CPPFLAGS}
 

Modified: brlcad/trunk/src/bwish/cmd.c
===================================================================
--- brlcad/trunk/src/bwish/cmd.c        2010-10-29 06:02:15 UTC (rev 41161)
+++ brlcad/trunk/src/bwish/cmd.c        2010-10-29 06:09:12 UTC (rev 41162)
@@ -51,8 +51,8 @@
 /***************************** BWISH/BTCLSH COMMANDS 
*****************************/
 
 HIDDEN int
-cmd_quit(ClientData clientData,
-        Tcl_Interp *interp,
+cmd_quit(ClientData UNUSED(clientData),
+        Tcl_Interp *UNUSED(interp),
         int argc,
         char **argv)
 {
@@ -150,7 +150,7 @@
  * Prints out the command history, either to bu_log or to a file.
  */
 int
-cmd_history(ClientData clientData, Tcl_Interp *interp, int argc, char **argv)
+cmd_history(ClientData UNUSED(clientData), Tcl_Interp *interp, int argc, char 
**argv)
 {
     FILE *fp;
     int with_delays = 0;
@@ -275,7 +275,7 @@
 
 
 int
-cmd_hist(ClientData clientData, Tcl_Interp *interp, int argc, char **argv)
+cmd_hist(ClientData UNUSED(clientData), Tcl_Interp *interp, int argc, char 
**argv)
 {
     struct bu_vls *vp;
     struct bu_vls vls;

Modified: brlcad/trunk/src/bwish/input.c
===================================================================
--- brlcad/trunk/src/bwish/input.c      2010-10-29 06:02:15 UTC (rev 41161)
+++ brlcad/trunk/src/bwish/input.c      2010-10-29 06:09:12 UTC (rev 41162)
@@ -78,7 +78,7 @@
 extern void history_record_priv(struct bu_vls *cmdp, struct timeval *start, 
struct timeval *finish, int status);
 
 /* defined in main.c */
-extern Tcl_Interp *interp;
+extern Tcl_Interp *INTERP;
 
 HIDDEN void inputHandler(ClientData clientData, int mask);
 HIDDEN void processChar(char ch);
@@ -112,13 +112,13 @@
 }
 
 HIDDEN void
-inputHandler(ClientData clientData, int mask)
+inputHandler(ClientData clientData, int UNUSED(mask))
 {
     int count;
     char ch;
     long fd;
     char buf[4096];
-    int index;
+    int i;
 
     fd = (long)clientData;
 
@@ -132,7 +132,7 @@
     }
 
     /* Process everything in buf */
-    for (index = 0, ch = buf[index]; index < count; ch = buf[++index])
+    for (i = 0, ch = buf[i]; i < count; ch = buf[++i])
        processChar(ch);
 }
 
@@ -176,9 +176,9 @@
 
                reset_Tty(fileno(stdin));
                gettimeofday(&start, (struct timezone *)NULL);
-               status = Tcl_Eval(interp, bu_vls_addr(&input_str_prefix));
+               status = Tcl_Eval(INTERP, bu_vls_addr(&input_str_prefix));
                gettimeofday(&finish, (struct timezone *)NULL);
-               result = Tcl_GetStringResult(interp);
+               result = Tcl_GetStringResult(INTERP);
                if (strlen(result))
                    bu_log("%s\n", result);
 

Modified: brlcad/trunk/src/bwish/main.c
===================================================================
--- brlcad/trunk/src/bwish/main.c       2010-10-29 06:02:15 UTC (rev 41161)
+++ brlcad/trunk/src/bwish/main.c       2010-10-29 06:09:12 UTC (rev 41162)
@@ -60,7 +60,7 @@
 Tk_Window tkwin;
 #endif
 
-Tcl_Interp *interp;
+Tcl_Interp *INTERP;
 
 
 static int
@@ -69,9 +69,11 @@
     int try_auto_path = 0;
 
     int init_tcl = 1;
+    int init_itcl = 1;
+#ifdef BWISH
     int init_tk = 1;
-    int init_itcl = 1;
     int init_itk = 1;
+#endif
 
     /* a two-pass init loop.  the first pass just tries default init
      * routines while the second calls tclcad_auto_path() to help it
@@ -276,8 +278,8 @@
 main(int argc, char **argv)
 {
     /* Create the interpreter */
-    interp = Tcl_CreateInterp();
-    Cad_Main(argc, argv, Cad_AppInit, interp);
+    INTERP = Tcl_CreateInterp();
+    Cad_Main(argc, argv, Cad_AppInit, INTERP);
 
     return 0;
 }


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to