Re: Serious Privileges Problem: Second Post!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Sat, Nov 07, 2009 at 10:23:11AM -0800, John R Pierce wrote:
> Kwan Lowe wrote:
> > On Sat, Nov 7, 2009 at 12:04 PM, Les Mikesell <lesmikesell@xxxxxxxxx> wrote:
> >
> >   
> >> How did you get it from machine to machine?  This could be a line-ending issue
> >> from a copy from windows or the wrong mode in ftp.
> >>     
> >
> > That is my guess too.   This exact error will happen if the file is
> > copied in Dos format to Linux.
> >   
> 
> ah, yes, python, where whitespace is  a syntax element

Not necessarily anything to do with python; a shell script or perl program
would suffer the same problem.

See if a file beginning "#!/bin/sh" was sent as a DOS file then Unix would
see it as "#!/bin/sh^M" (where ^M is the carriage-return character 0x0d)
and so would try to run the script under "/bin/sh^M".  This, clearly,
doesn't exit.  Same would be true for /usr/bin/perl^M or /usr/bin/python^M
and so on.

Victor was told do to "dos2unix" which fixes the problem but he ignored
the info ("dos2unix?! Huh? Where's the dos?") so *shrug*

As they say, you can lead a horse to water...

-- 

rgds
Stephen
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux