This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: Problems with "sed -i"
- From: Corinna Vinschen <corinna-cygwin at cygwin dot com>
- To: Cygwin ML <cygwin at cygwin dot com>
- Date: Mon, 14 May 2007 17:14:30 +0200
- Subject: Re: Problems with "sed -i"
- References: <4628A2F9.2000200@bonhard.uklinux.net>
- Reply-to: cygwin at cygwin dot com
On Apr 20 12:24, fergus wrote:
> I'm having a few problems with sed -i (using the current sed v.4.1.5).
>
> Unfortunately they only occur when used in a system() call from within a
> program. That is to say
>
> $ /bin/sed -i 's/expr1/expr2/g' {pathto}/filename
>
> works fine, but
>
> system("/bin/sed -i 's/expr1/expr2/g' {pathto}/filename")
> .. do stuff involving filename ..
>
> invariably results in error messages of the style
>
> /bin/sed: cannot rename {pathto}//sedEfWWjX: Permission denied
I can't reproduce this. I tried with removing TMP, TEMP and TMPDIR
from my environment, but it "just works"(tm). Looks like you have to
debug this a bit more on your own machine.
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
Red Hat
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/