From mboxrd@z Thu Jan 1 00:00:00 1970 Subject: Re: [9fans] bug in libcomplete? Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v553) From: Rob Pike To: 9fans@cse.psu.edu Content-Transfer-Encoding: 7bit In-Reply-To: Message-Id: Date: Sat, 14 Feb 2004 08:35:48 -0800 Topicbox-Message-UUID: e3ec4556-eacc-11e9-9e20-41e7f4b1d025 no, the bug is rio. it doesn't set /dev/wdir in this case. add if(dir) w->dir = estrdup(dir) after the call to wsetname() in new() in /sys/src/cmd/rio/rio.c -rob On Saturday, February 14, 2004, at 07:15 AM, andrey mirtchovski wrote: > libcomplete depends on 'cd' to find our which directory the user is > in. this breaks its behaviour with respect to programs which > implicitly chdir when started, one example is the 'window' command -- > cd /tmp and run window, hit the complete key and you'll get the > contents of your $home. The following example is a freshly created > window in the /tmp directory: > > > > home% pwd > /tmp > [bin/ lib/ tmp/] > home% cd `{pwd} > [58 files] > home% > > pwd shows i'm in /tmp, completion thinks i'm in $home, then the same > thing after "cd `{pwd}" > > andrey