@xenic
I messed it up a bit, sorry...
In fact, what was the problem is, that when using unix paths, and trying to create a root level entry (for instance '/MainHD'), you will be given an error code of ENOTDIR == 20 instad of EEXIST == 17.
Quote:
#include <unistd.h>
#include <sys/stat.h>
#include <stdio.h>
#include <errno.h>
int main()
{
if(mkdir("/MainHD", 0777) != 0)
printf("Error: %ld\n", errno);
return 0;
}
(To be built with '-lunix')
It is the same, if you try and mkdir("MainHD:", 0777);
Edited by alfkil on 2017/2/1 19:42:26