bug-hurd
[Top][All Lists]
Advanced

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

[PATCH] make libdiskfs handle _PC_PATH_MAX


From: Pino Toscano
Subject: [PATCH] make libdiskfs handle _PC_PATH_MAX
Date: Wed, 19 Oct 2011 00:09:32 +0200
User-agent: KMail/1.13.7 (Linux/3.0.0-1-amd64; KDE/4.6.5; x86_64; ; )

Hi,

currently, querying (f)pathconf() for _PC_PATH_MAX return -1 and sets 
errno = EINVAL. At least to my reading of pathconf() in POSIX, when a 
variable has no limit pathconf() for it should return -1 and not change 
errno. For example:
  $ getconf PATH_MAX .
  getconf: pathconf: .: Invalid argument
fpathconf() just queries the translator which handles the specified 
path, so the fix I thought about is to make the io_pathconf() reply in 
libdiskfs handle _PC_PATH_MAX too among the other cases of "set -1 and 
return 0".

With the applied path, I correctly get:
  $ getconf PATH_MAX .
  undefined

-- 
Pino Toscano

Attachment: 0001-libdiskfs-handle-_PC_PATH_MAX-in-pathconf.patch
Description: Text Data

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]