Am 10.09.2011 13:49, schrieb Denys Vlasenko:
> On Saturday 10 September 2011 12:57, Matthias Andree wrote:
>> Am 10.09.2011 04:31, schrieb Denys Vlasenko:
>>> On Thursday 14 July 2011 11:57, Matthias Andree wrote:
>>>> - Is there a particular reason the sed scripts use GNU extensions or
>>>> syntax?  What are the chances of these being replaced by POSIX default
>>>> constructs (If none, add: possibly if I submit a patch)?
>>>
>>> Since I use GNU or busybox sed, I don't know where we use
>>> extensions. Where exactly is the problem?
>>
>> ISTR I replied to this message before, but I'll see what I can find out
>> about awk.  It's a minor issue at any rate.
>>
>>> We probably need to remove the #if around this decl in libbb.h:
>>>
>>> #if !defined __FreeBSD__
>>> char *dirname(char *path);
>>> #endif
>>>
>>> Can you confirm that it helps?
>>
>> It's bogus because ours is const char *.
>>
>> #include <libgen.h> is the way. I think I've made that clear through
>> various messages on the list (which you may be reading later according
>> to the order in which you process your inbox).
> 
> How about this?
> 
> http://git.busybox.net/busybox/commit/?id=d48fdde3704f453014404fca321e08238dc4acc4
> 

It is confusing.

What is the business with *REMOVING* <libgen.h>?

What has the basename() stuff got to do with this dirname() abuse you
are trying to fix?

What good is the reference to the basename manual page?  It's
system-specific and may not explain the problem you're trying to avoid.

Perhaps if all callers of basename() in busybox made the most
conservative assumptions possible (i. e. (a) overwrites its argument,
(b) uses a static buffer) all this hassle need not be made.
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to