Subject: standards/18764: mkdir(2) not POSIX 1003.1-1996 compliant
To: None <>
From: None <>
List: netbsd-bugs
Date: 10/22/2002 14:38:42
>Number:         18764
>Category:       standards
>Synopsis:       mkdir("/tmp/test/", 0777)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    standards-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Tue Oct 22 05:41:00 PDT 2002
>Originator:     Matthias Friedrich
>Release:        NetBSD 1.6
System: NetBSD 1.6 NetBSD 1.6 (ALANIS) #0: Tue Oct 15 21:57:54 CEST 2002 i386
Architecture: i386
Machine: i386
	NetBSD's mkdir(2) fails when called with an argument that has
	one or more trailing slashes. While this seems to be OK with
	POSIX 1003.1-1990, POSIX 1003.1-1996 explicitly allows trailing

	Linux's mkdir(2) is compliant BTW, so I noticed this behaviour
	while migrating my system to NetBSD. It took me some time to
	find out that there was a perl bug resulting in perl not removing
	the slashes (see 'perldoc -f mkdir') and finally the unexpected
	behaviour of NetBSD. The bug in perl has been reported and fixed,
	so it would be cool if NetBSD's code could be changed, too, to
	regain compatibility with Linux for non-perl applications.