Quantcast

setting CYGWIN=nodosfilewarning not working.

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

setting CYGWIN=nodosfilewarning not working.

prakash babu-3
I have a web application which runs as SYSTEM user in windows.
It executes the following command using Java Runtime.exec api's
C:/cygwin/bin/sh.exe -c C:/cygwin/bin/mkdir.exe -p 'C:/cygwin/tmpdir'

The command executes fine but I get the following warning.

cygwin warning:
  MS-DOS style path detected: C:/cygwin
  Preferred POSIX equivalent is: /
  CYGWIN environment variable option "nodosfilewarning" turns off this warning.
  Consult the user's guide for more details about POSIX paths:
    http://cygwin.com/cygwin-ug-net/using.html#using-pathnames

To suppress this warning I set the environment variable CYGWIN=nodosfilewarning by MyComputer-->Advanced-->EnvironmentVariables, but still I am getting this warning.

Is there any other way to set the CYGWIN environment variable.


thanks,
Prakash




     

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: setting CYGWIN=nodosfilewarning not working.

Eric Blake-3
On 06/10/2010 05:55 AM, prakash babu wrote:
> I have a web application which runs as SYSTEM user in windows.
> It executes the following command using Java Runtime.exec api's
> C:/cygwin/bin/sh.exe -c C:/cygwin/bin/mkdir.exe -p 'C:/cygwin/tmpdir'
>
> The command executes fine but I get the following warning.

Better yet, don't trigger the warning in the first place, by using POSIX
paths from the get-go:

c:/cygwin/bin/sh.exe -c /cygdrive/c/cygwin/bin/mkdir.exe -p
'/cygdrive/c/cygwin/tmpdir'

--
Eric Blake   [hidden email]    +1-801-349-2682
Libvirt virtualization library http://libvirt.org


signature.asc (632 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: setting CYGWIN=nodosfilewarning not working.

prakash babu-3
True, but what about existing applications. Since this warning comes in the error stream the command is considered as failed in the existing application.

thanks,
Prakash

--- On Thu, 6/10/10, Eric Blake <[hidden email]> wrote:

> From: Eric Blake <[hidden email]>
> Subject: Re: setting CYGWIN=nodosfilewarning not working.
> To: [hidden email], [hidden email]
> Date: Thursday, June 10, 2010, 5:30 PM
> On 06/10/2010 05:55 AM, prakash babu
> wrote:
> > I have a web application which runs as SYSTEM user in
> windows.
> > It executes the following command using Java
> Runtime.exec api's
> > C:/cygwin/bin/sh.exe -c C:/cygwin/bin/mkdir.exe -p
> 'C:/cygwin/tmpdir'
> >
> > The command executes fine but I get the following
> warning.
>
> Better yet, don't trigger the warning in the first place,
> by using POSIX
> paths from the get-go:
>
> c:/cygwin/bin/sh.exe -c /cygdrive/c/cygwin/bin/mkdir.exe
> -p
> '/cygdrive/c/cygwin/tmpdir'
>
> --
> Eric Blake   [hidden email] 
>   +1-801-349-2682
> Libvirt virtualization library http://libvirt.org
>
>




--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: setting CYGWIN=nodosfilewarning not working.

Andy Koppe
In reply to this post by prakash babu-3
On 10 June 2010 12:55, prakash babu wrote:

> I have a web application which runs as SYSTEM user in windows.
> It executes the following command using Java Runtime.exec api's
> C:/cygwin/bin/sh.exe -c C:/cygwin/bin/mkdir.exe -p 'C:/cygwin/tmpdir'
>
> The command executes fine but I get the following warning.
>
> cygwin warning:
>  MS-DOS style path detected: C:/cygwin
>  Preferred POSIX equivalent is: /
>  CYGWIN environment variable option "nodosfilewarning" turns off this warning.
>  Consult the user's guide for more details about POSIX paths:
>    http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
>
> To suppress this warning I set the environment variable CYGWIN=nodosfilewarning by MyComputer-->Advanced-->EnvironmentVariables, but still I am getting this warning.

Make sure you set it under "System variables" rather than "User
variables for ...".

Andy

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: setting CYGWIN=nodosfilewarning not working.

prakash babu-3

I tried setting it in the under the System Variables section  but still I am getting this warning.

Is there any other way to set the CYGWIN env variable.

thanks,
Prakash

--- On Thu, 6/10/10, Andy Koppe <[hidden email]> wrote:

> From: Andy Koppe <[hidden email]>
> Subject: Re: setting CYGWIN=nodosfilewarning not working.
> To: [hidden email]
> Date: Thursday, June 10, 2010, 7:04 PM
> On 10 June 2010 12:55, prakash babu
> wrote:
> > I have a web application which runs as SYSTEM user in
> windows.
> > It executes the following command using Java
> Runtime.exec api's
> > C:/cygwin/bin/sh.exe -c C:/cygwin/bin/mkdir.exe -p
> 'C:/cygwin/tmpdir'
> >
> > The command executes fine but I get the following
> warning.
> >
> > cygwin warning:
> >  MS-DOS style path detected: C:/cygwin
> >  Preferred POSIX equivalent is: /
> >  CYGWIN environment variable option
> "nodosfilewarning" turns off this warning.
> >  Consult the user's guide for more details about
> POSIX paths:
> >    http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
> >
> > To suppress this warning I set the environment
> variable CYGWIN=nodosfilewarning by
> MyComputer-->Advanced-->EnvironmentVariables, but
> still I am getting this warning.
>
> Make sure you set it under "System variables" rather than
> "User
> variables for ...".
>
> Andy
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:               
>    http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>
>




--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: setting CYGWIN=nodosfilewarning not working.

Larry Hall (Cygwin)
On 6/10/2010 11:57 AM, prakash babu wrote:
>
> I tried setting it in the under the System Variables section  but still I am
> getting this warning.
>
> Is there any other way to set the CYGWIN env variable.

It's unclear if you're running this as a service or not.  If you are,
you need to restart the service.

--
Larry Hall                              http://www.rfk.com
RFK Partners, Inc.                      (508) 893-9779 - RFK Office
216 Dalton Rd.                          (508) 893-9889 - FAX
Holliston, MA 01746

_____________________________________________________________________

A: Yes.
> Q: Are you sure?
>> A: Because it reverses the logical flow of conversation.
>>> Q: Why is top posting annoying in email?

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: setting CYGWIN=nodosfilewarning not working.

Andrey Repin-3
In reply to this post by prakash babu-3
Greetings, prakash babu!

> I tried setting it in the under the System Variables section  but still I am getting this warning.

Then,
1. You didn't rebooted your system after setting the variable.
2. The host application clearing the environment before calling your
application.

> Is there any other way to set the CYGWIN env variable.

Probably.


--
WBR,
 Andrey Repin ([hidden email]) 11.06.2010, <13:20>

Sorry for my terrible english...


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: setting CYGWIN=nodosfilewarning not working.

Julio Costa
In reply to this post by prakash babu-3
On Thu, Jun 10, 2010 at 12:55, prakash babu wrote:
> I have a web application which runs as SYSTEM user in windows.
> It executes the following command using Java Runtime.exec api's
> C:/cygwin/bin/sh.exe -c C:/cygwin/bin/mkdir.exe -p 'C:/cygwin/tmpdir'
>
(snip)
>
> Is there any other way to set the CYGWIN environment variable.
>

Yes there are. Try launching like this:

C:/cygwin/bin/sh.exe -c "CYGWIN=nodosfilewarning /bin/mkdir -p
'C:/cygwin/tmpdir'"

--
___________
Julio Costa

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Loading...