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

Re: broken sysvinit?



On Fri, Jun 23, 2000 at 05:27:32PM +0200, Josip Rodin wrote:
> 
> > No, the exec command can be used to open, close, or reassign file
> > descriptors.  In this case, it temporarily reassigns stdin to fd 10,
> > so that it can use stdin for parsing fstab.  Then later in the script
> > it reassigns fd 10 back to stdin.
> > 
> > Unfortunately ash only understands single-digit filedescriptors, it
> > appears:
> > 
> > $ exec 2>&1
> > $ exec 9>&1
> > $ exec 10>&1    
> > exec: 10: not found
> 
> Quick fix would be to use 9, unless ash can be fixed in the same time.

To quote Single Unix:

Open files are represented by decimal numbers starting with zero. The largest
possible value is implementation-dependent; however, all implementations
support at least 0 to 9, inclusive, for use by the application.
-- 
Debian GNU/Linux 2.1 is out! ( http://www.debian.org/ )
Email:  Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt



Reply to: