rpmmacro.h (rpmGetPath, rpmExpand): Add __attribute__ ((sentinel))

This commit is contained in:
Дмитрий Левин 2008-11-13 01:38:17 +00:00
parent 0a48c3206e
commit 328d65def9
3 changed files with 5 additions and 3 deletions

View File

@ -274,7 +274,7 @@ static int buildForTarget(const char * arg, BTA_t ba,
}
#undef _anyarch
char *br_build = rpmExpand("%{?_buildrequires_build}", 0);
char *br_build = rpmExpand("%{?_buildrequires_build}", NULL);
if (spec->packages && br_build && *br_build) {
if (parseRCPOT (spec, spec->packages, br_build, RPMTAG_BUILDREQUIRES, 0, RPMSENSE_SCRIPT_BUILD)) {
rc = 1;

View File

@ -2880,7 +2880,7 @@ static int generateDepends(Spec spec, Package pkg, TFI_t cpioList, int multiLib)
Fclose(xfd);
runCmd = rpmExpand( "%{?___build_cmd}", " ", runScript, 0 );
runCmd = rpmExpand("%{?___build_cmd}", " ", runScript, NULL);
poptParseArgvString(runCmd, &argc, &argv);
@ -3148,7 +3148,7 @@ static int checkFiles(Spec spec, StringBuf fileList, int fileListLen)
Fclose(xfd);
runCmd = rpmExpand( "%{?___build_cmd}", " ", runScript, 0 );
runCmd = rpmExpand("%{?___build_cmd}", " ", runScript, NULL);
if (!((rc = poptParseArgvString(runCmd, &ac, (const char ***)&av)) == 0
&& ac > 0 && av != NULL))

View File

@ -172,6 +172,7 @@ int isCompressed (const char * file,
* @return macro expansion (malloc'ed)
*/
char * rpmExpand (/*@null@*/ const char * arg, ...)
__attribute__ ((sentinel))
/*@globals rpmGlobalMacroContext @*/
/*@modifies rpmGlobalMacroContext @*/;
@ -190,6 +191,7 @@ char * rpmExpand (/*@null@*/ const char * arg, ...)
*/
/*@-redecl@*/ /* LCL: shrug */
const char * rpmGetPath (/*@null@*/ const char * path, ...)
__attribute__ ((sentinel))
/*@globals rpmGlobalMacroContext @*/
/*@modifies rpmGlobalMacroContext @*/;
/*@=redecl@*/