See through
        ===> signify
        
/usr/src/distrib/special/signify/../../../usr.bin/signify/signify.c:754:34: 
warning: variable 'seckeyfile' set but not used [-Wunused-but-set-variable]
                const char *pubkeyfile = NULL, *seckeyfile = NULL, *msgfile = 
NULL,
                                                ^
        
/usr/src/distrib/special/signify/../../../usr.bin/signify/signify.c:757:14: 
warning: variable 'comment' set but not used [-Wunused-but-set-variable]
                const char *comment = "signify";
                            ^
        
/usr/src/distrib/special/signify/../../../usr.bin/signify/signify.c:760:6: 
warning: variable 'none' set but not used [-Wunused-but-set-variable]
                int none = 0;
                    ^
        3 warnings generated.

install media obviously does not use any of -cns.

OK?

Index: signify.c
===================================================================
RCS file: /cvs/src/usr.bin/signify/signify.c,v
retrieving revision 1.135
diff -u -p -r1.135 signify.c
--- signify.c   21 Jan 2020 12:13:21 -0000      1.135
+++ signify.c   25 Aug 2022 21:41:56 -0000
@@ -751,13 +751,14 @@ verifyzdata(uint8_t *zdata, unsigned lon
 int
 main(int argc, char **argv)
 {
-       const char *pubkeyfile = NULL, *seckeyfile = NULL, *msgfile = NULL,
-           *sigfile = NULL;
+       const char *pubkeyfile = NULL, *msgfile = NULL, *sigfile = NULL;
        char sigfilebuf[PATH_MAX];
-       const char *comment = "signify";
        char *keytype = NULL;
-       int ch;
+#ifndef VERIFYONLY
+       const char *seckeyfile = NULL, *comment = "signify";
        int none = 0;
+#endif
+       int ch;
        int embedded = 0;
        int quiet = 0;
        int gzip = 0;
@@ -790,6 +791,15 @@ main(int argc, char **argv)
                                usage(NULL);
                        verb = SIGN;
                        break;
+               case 'c':
+                       comment = optarg;
+                       break;
+               case 'n':
+                       none = 1;
+                       break;
+               case 's':
+                       seckeyfile = optarg;
+                       break;
                case 'z':
                        gzip = 1;
                        break;
@@ -799,26 +809,17 @@ main(int argc, char **argv)
                                usage(NULL);
                        verb = VERIFY;
                        break;
-               case 'c':
-                       comment = optarg;
-                       break;
                case 'e':
                        embedded = 1;
                        break;
                case 'm':
                        msgfile = optarg;
                        break;
-               case 'n':
-                       none = 1;
-                       break;
                case 'p':
                        pubkeyfile = optarg;
                        break;
                case 'q':
                        quiet = 1;
-                       break;
-               case 's':
-                       seckeyfile = optarg;
                        break;
                case 't':
                        keytype = optarg;

Reply via email to