Thanks in advance,
Kris
As for FEcreat, the API call dates back to NW3 which means that it was
developed to support the 8.3 file names of DOS 5.
Roger Thomas, Dev SysOp 22
"teradactyl" <kw...@teradactyl.com> wrote in message news:k58je.549$252...@prv-forum2.provo.novell.com...
Cannot reproduce. When I run the program below with parameter "nssvol1:
123", it creates file " 123" without removing the leading space. Are you
sure your program is setting the correct source name space before creating
files?
#include <errno.h>
#include <fcntl.h>
#include <nwerrno.h>
#include <nwfileng.h>
#include <nwnspace.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
int main( int argc, char* argv[]) {
int handle;
if ( argc != 2) {
printf( "Usage: %s <file>\n", argv[ 0]);
return EXIT_FAILURE;
}
printf( "file = '%s'\n", argv[ 1]);
SetCurrentNameSpace( LONGNameSpace);
handle = FEsopen( argv[ 1], O_WRONLY|O_CREAT|O_TRUNC, SH_DENYRW, 0,
DELETE_FILE_ON_CREATE_BIT, PrimaryDataStream);
if ( handle == -1) {
printf( "FEsopen failed, errno = %d (%s), NetWareErrno = %d\n", errno,
strerror( errno), NetWareErrno);
return EXIT_FAILURE;
}
close( handle);
return EXIT_SUCCESS;
}
--
Dmitry Mityugov, Developer Services SysOp 8
Search these newsgroups for answers to similar questions:
http://developer.novell.com/ndk/devforums.htm
Search DevSup Samples and TIDs:
http://developer.novell.com/support/sample.htm
Search KnowledgeBase and manuals:
http://support.novell.com/search/kb_index.jsp
Search YES, Tested and Approved Products:
http://developer.novell.com/yessearch/Search.jsp
Search Samples and Projects at Novell Forge:
http://forge.novell.com