> > assuming that every application that uses webfs is prepared > > to handle a null byte in the middle of a string. what webfs does > > — complaining loudly — is much preferrable to programs misbehaving > > silently. since it's quite likely that plan 9 applications are not > > going to properly deal with a null in a string, it's probablly > > a good implementation strategy unless you're willing to test > > all the programs that use webfs to make sure that this case > > is properly handled. > > Ok, but then valid applications such as this one can't use webfs. I > think something needing this could solve the issue by having the > application import webfs into its own namespace, and then sending some > sort of ctl command telling it to set an option to allow null bytes.
read to the end: > > unless you're willing to test > > all the programs that use webfs to make sure that this case > > is properly handled. i think it would be a bad idea to add a control swizzle bit to avoid testing. testing is not that hard. grep webfs `{find /sys/src /rc/bin |grep '\.[chy]$'} | grep -v /webfs/ /sys/src/cmd/webcookies.c: * Cookie file system. Allows hget and multiple webfs's to collaborate. /sys/src/cmd/webfsget.c:/* Example of how to use webfs */ /sys/src/cmd/webfsget.c: fprint(2, "usage: webfsget [-b baseurl] [-m mtpt] [-p postbody] url\n"); you can search contrib, too. i'm sure that abaco falls on its face when confronted with a 0 in a url. - erik