Ticket #203 (closed defect: fixed)
filter_env thinks functionfoo is foo
| Reported by: | ferdy | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 0.4.7.3 |
| Component: | pkgcore | Version: | 0.4.7.4 |
| Keywords: | Cc: |
Description
09:15 < ferdy> ferringb: you might want to apply: http://rafb.net/p/IhrT5n55.html . Otherwise it treats 'functionfoo' as 'foo'. 11:41 < ferringb> ferdy: doesn't work with function\nfoo 11:41 < ferringb> ferdy: or function\tfoo # a more likely example 11:41 < ferringb> ferdy: nice catch though 11:42 < ferringb> ferdy: question is, what ebuild? 11:43 < ferdy> no ebuild. Spotted it while reading through the code
That paste has (even if it is not correct, just as a reference):
=== modified file 'src/filter_env.c'
--- src/filter_env.c 2008-06-11 03:01:16 +0000
+++ src/filter_env.c 2008-06-23 07:10:51 +0000
@@ -68,9 +68,9 @@
{
#define SKIP_SPACES(p) while('\0' != *(p) && \
(' ' == *(p) || '\t' == *(p))) ++p;
- #define FUNC_LEN 8
+ #define FUNC_LEN 9
SKIP_SPACES(p);
- if(strncmp(p, "function", FUNC_LEN) == 0)
+ if(strncmp(p, "function ", FUNC_LEN) == 0)
p += FUNC_LEN;
while('\0' != *p && isspace(*p))
++p;
- ferdy
Change History
Note: See
TracTickets for help on using
tickets.
