diff options
author | jbj <devnull@localhost> | 2001-10-13 22:01:38 +0000 |
---|---|---|
committer | jbj <devnull@localhost> | 2001-10-13 22:01:38 +0000 |
commit | 4b67d7621c20e1f2c5aa1ebdf7bb26eb3a6ae0d5 (patch) | |
tree | e9f6fa3bae9cc045fdd4f716ac747c1cad5e103e /popt | |
parent | 525f4cb8b1317120c36a75f47f796d285f69078c (diff) | |
download | rpm-4b67d7621c20e1f2c5aa1ebdf7bb26eb3a6ae0d5.tar.gz rpm-4b67d7621c20e1f2c5aa1ebdf7bb26eb3a6ae0d5.tar.bz2 rpm-4b67d7621c20e1f2c5aa1ebdf7bb26eb3a6ae0d5.zip |
More lclint annotations.
CVS patchset: 5105
CVS date: 2001/10/13 22:01:38
Diffstat (limited to 'popt')
-rw-r--r-- | popt/po/popt.pot | 24 | ||||
-rw-r--r-- | popt/popt.c | 27 | ||||
-rw-r--r-- | popt/poptconfig.c | 6 | ||||
-rw-r--r-- | popt/poptparse.c | 4 |
4 files changed, 33 insertions, 28 deletions
diff --git a/popt/po/popt.pot b/popt/po/popt.pot index 75e5f3c83..349c30490 100644 --- a/popt/po/popt.pot +++ b/popt/po/popt.pot @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2001-10-13 13:15-0400\n" +"POT-Creation-Date: 2001-10-13 17:57-0400\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Language-Team: LANGUAGE <LL@li.org>\n" @@ -18,48 +18,48 @@ msgstr "" msgid "unknown errno" msgstr "" -#: popt.c:892 +#: popt.c:896 #, c-format msgid "option type (%d) not implemented in popt\n" msgstr "" -#: popt.c:1100 +#: popt.c:1105 msgid "missing argument" msgstr "" -#: popt.c:1102 +#: popt.c:1107 msgid "unknown option" msgstr "" -#: popt.c:1104 +#: popt.c:1109 msgid "mutually exclusive logical operations requested" msgstr "" -#: popt.c:1106 +#: popt.c:1111 msgid "opt->arg should not be NULL" msgstr "" -#: popt.c:1108 +#: popt.c:1113 msgid "aliases nested too deeply" msgstr "" -#: popt.c:1110 +#: popt.c:1115 msgid "error in parameter quoting" msgstr "" -#: popt.c:1112 +#: popt.c:1117 msgid "invalid numeric value" msgstr "" -#: popt.c:1114 +#: popt.c:1119 msgid "number too large or too small" msgstr "" -#: popt.c:1116 +#: popt.c:1121 msgid "memory allocation failed" msgstr "" -#: popt.c:1120 +#: popt.c:1125 msgid "unknown error" msgstr "" diff --git a/popt/popt.c b/popt/popt.c index c4fa4eea0..e90b08f59 100644 --- a/popt/popt.c +++ b/popt/popt.c @@ -505,9 +505,12 @@ static const char * findNextArg(/*@special@*/ poptContext con, if (os->next == os->argc && os == con->optionStack) break; if (os->argv != NULL) for (i = os->next; i < os->argc; i++) { - if (os->argb && PBM_ISSET(i, os->argb)) continue; - if (*os->argv[i] == '-') continue; - if (--argx > 0) continue; + if (os->argb && PBM_ISSET(i, os->argb)) + /*@innercontinue@*/ continue; + if (*os->argv[i] == '-') + /*@innercontinue@*/ continue; + if (--argx > 0) + /*@innercontinue@*/ continue; arg = os->argv[i]; if (delete_arg) { if (os->argb == NULL) os->argb = PBM_ALLOC(os->argc); @@ -540,14 +543,15 @@ expandNextArg(/*@special@*/ poptContext con, const char * s) #if 0 /* XXX can't do this */ case '\\': /* escape */ c = *s++; - break; + /*@switchbreak@*/ break; #endif case '!': if (!(s[0] == '#' && s[1] == ':' && s[2] == '+')) - break; + /*@switchbreak@*/ break; /* XXX Make sure that findNextArg deletes only next arg. */ if (a == NULL) { - if ((a = findNextArg(con, 1, 1)) == NULL) break; + if ((a = findNextArg(con, 1, 1)) == NULL) + /*@switchbreak@*/ break; } s += 3; @@ -558,9 +562,9 @@ expandNextArg(/*@special@*/ poptContext con, const char * s) te = t + strlen(t); strncpy(te, a, alen); te += alen; continue; - /*@notreached@*/ break; + /*@notreached@*/ /*@switchbreak@*/ break; default: - break; + /*@switchbreak@*/ break; } *te++ = c; } @@ -834,7 +838,7 @@ int poptGetNextOpt(poptContext con) /* XXX memory leak, hard to plug */ *((const char **) opt->arg) = (con->os->nextArg) ? xstrdup(con->os->nextArg) : NULL; - break; + /*@switchbreak@*/ break; case POPT_ARG_INT: case POPT_ARG_LONG: @@ -858,7 +862,7 @@ int poptGetNextOpt(poptContext con) if (poptSaveInt(opt, aLong)) return POPT_ERROR_BADOPERATION; } - } break; + } /*@switchbreak@*/ break; case POPT_ARG_FLOAT: case POPT_ARG_DOUBLE: @@ -886,12 +890,13 @@ int poptGetNextOpt(poptContext con) return POPT_ERROR_OVERFLOW; *((float *) opt->arg) = aDouble; } - } break; + } /*@switchbreak@*/ break; default: fprintf(stdout, POPT_("option type (%d) not implemented in popt\n"), (opt->argInfo & POPT_ARG_MASK)); exit(EXIT_FAILURE); + /*@notreached@*/ /*@switchbreak@*/ break; } } } diff --git a/popt/poptconfig.c b/popt/poptconfig.c index 1801db63e..bc902d4e7 100644 --- a/popt/poptconfig.c +++ b/popt/poptconfig.c @@ -126,7 +126,7 @@ int poptReadConfigFile(poptContext con, const char * fn) if (*dst && *dst != '#') configLine(con, dst); chptr++; - break; + /*@switchbreak@*/ break; case '\\': *dst++ = *chptr++; if (chptr < end) { @@ -136,10 +136,10 @@ int poptReadConfigFile(poptContext con, const char * fn) else *dst++ = *chptr++; } - break; + /*@switchbreak@*/ break; default: *dst++ = *chptr++; - break; + /*@switchbreak@*/ break; } } /*@=infloops@*/ diff --git a/popt/poptparse.c b/popt/poptparse.c index fdce57286..f9faae32b 100644 --- a/popt/poptparse.c +++ b/popt/poptparse.c @@ -90,7 +90,7 @@ int poptParseArgvString(const char * s, int * argcPtr, const char *** argvPtr) case '"': case '\'': quote = *src; - break; + /*@switchbreak@*/ break; case '\\': src++; if (!*src) { @@ -100,7 +100,7 @@ int poptParseArgvString(const char * s, int * argcPtr, const char *** argvPtr) /*@fallthrough@*/ default: *buf++ = *src; - break; + /*@switchbreak@*/ break; } } |