1 #include "pwd.h" 2 #include <stdio.h> 3 #include <unixlib.h> 4 5 #ifndef __VMS_VER 6 #define __VMS_VER 0 7 #endif 8 #ifndef __DECC_VER 9 #define __DECC_VER 0 10 #endif 11 12 #if __VMS_VER < 70200000 || __DECC_VER < 50700000 13 14 static struct passwd pw; 15 16 /* This is only called from one relevant place, lock.c. In that context 17 the code is really trying to figure out who owns a directory. Nothing 18 which has anything to do with getpwuid or anything of the sort can help 19 us on VMS (getuid returns only the group part of the UIC). */ 20 struct passwd *getpwuid(unsigned int uid) 21 { 22 return NULL; 23 } 24 25 char *getlogin() 26 { 27 static char login[256]; 28 return cuserid(login); 29 } 30 31 #else /* __VMS_VER >= 70200000 && __DECC_VER >= 50700000 */ 32 #pragma message disable EMPTYFILE 33 #endif /* __VMS_VER >= 70200000 && __DECC_VER >= 50700000 */ 34