Subject: wierd behaviour of mkdir(2)
To: , <tech-misc@netbsd.org>
From: Yoav Cohen-Sivan <yoavcs@zahav.net.il>
List: tech-kern
Date: 10/19/2000 22:18:07
This is a multi-part message in MIME format.

------=_NextPart_000_000D_01C03A1A.74EC0740
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

In the process of installing KDE 2 on NetBSD/i386-ALPHA2 (14/10/00 code) =
I came across an unusual problem. KDE was failing to work properly, =
constantly crashing. I managed to track the problem to KDE's inability =
to create its dir structure under the user's home directory during =
initial startup.  Using ktrace I found numerous failed calls to mkdir(2) =
while trying to create this dir hierarchy.
KDE is trying to do a mkdir("/home/yoavcs/.kde/share/",xxxxx) and mkdir =
is failing wih an errno of "no such file or directory". I compiled a =
small program of my own and discovered that when mkdir is called as =
above with the trailing '/' it fails. Call it without the trailing '/' =
("/home/yoavcs/.kde/share") and all works peachy.=20
Is this a fault of mkdir(2) or KDE?! It is a shame since once I manually =
created the entire dir structure under my home dir KDE 2 works =
wonderfully.

Yoav


------=_NextPart_000_000D_01C03A1A.74EC0740
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 5.50.4134.600" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>In the process of installing KDE 2 on=20
NetBSD/i386-ALPHA2 (14/10/00 code) I came across an unusual problem.=20
KDE&nbsp;was failing to work properly, constantly crashing. I managed to =
track=20
the problem to KDE's inability to create its dir structure under the =
user's home=20
directory during&nbsp;initial startup.&nbsp;&nbsp;Using ktrace I found =
numerous=20
failed calls to mkdir(2) while trying to create&nbsp;this dir=20
hierarchy.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>KDE is trying to do a=20
mkdir("/home/yoavcs/.kde/share/",xxxxx) and mkdir is failing wih an =
errno of "no=20
such file or directory". I compiled a small program of my own and =
discovered=20
that when mkdir is called as above with the trailing '/' it fails. Call =
it=20
without the trailing '/' ("/home/yoavcs/.kde/share") and all works =
peachy.=20
</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Is this a fault of mkdir(2) or KDE?! It =
is a shame=20
since once I manually created the entire dir structure under my home dir =
KDE 2=20
works wonderfully.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Yoav</FONT></DIV>
<DIV>&nbsp;</DIV></BODY></HTML>

------=_NextPart_000_000D_01C03A1A.74EC0740--