[Rpm-maint] [rpm-software-management/rpm] Add shell-like escape support to %files (PR #2103)

Panu Matilainen notifications at github.com
Thu Jun 23 10:44:17 UTC 2022


@pmatilai commented on this pull request.



> @@ -85,34 +84,27 @@ static int __glob_pattern_p(const char *pattern, int quote)
 
 /* librpmio exported interfaces */
 
-int rpmGlob(const char * patterns, int * argcPtr, ARGV_t * argvPtr)
+int rpmGlob(const char * pattern, int * argcPtr, ARGV_t * argvPtr)

This change needs to be reflected in the corresponding header too. This being a public API function, it's technically silent breakage for anybody relying on the old behavior so generally it'd be better to introduce a new function to force the break, BUT. I don't think anybody is using this API outside rpm itself, and the fact that it accepts multiple patterns was never documented anywhere besides the "s" in the argument name. So we can always just call that a typo :laughing:

Just update the header and I think it'll be fine. Accepting multiple whitespace separated patterns there is just a terrible API. If we needed multiple patterns we could pass them in via ARGV_t, but not like this. It's a good thing to address the issue at the source, really.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/2103#pullrequestreview-1016789208
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/pull/2103/review/1016789208 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20220623/2d5fe946/attachment-0001.html>


More information about the Rpm-maint mailing list