- Timestamp:
- Oct 7, 2007, 4:19:01 PM (18 years ago)
- Location:
- trunk/src/kash
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kash/Makefile.kmk
r1203 r1204 47 47 exec.c \ 48 48 expand.c \ 49 miscbltin.c \ 49 50 \ 50 51 jobs.c \ 51 miscbltin.c \52 52 parser.c \ 53 53 redir.c \ -
trunk/src/kash/miscbltin.c
r1203 r1204 48 48 */ 49 49 50 #include <sys/types.h> /* quad_t */ 51 #include <sys/param.h> /* BSD4_4 */ 50 #include <sys/types.h> 52 51 #include <sys/stat.h> 53 52 #include <sys/time.h> … … 57 56 #include <ctype.h> 58 57 #include <errno.h> 58 #ifndef _MSC_VER 59 # include "mscfakes.h" 60 #endif 59 61 60 62 #include "shell.h" … … 89 91 90 92 int 91 readcmd( int argc, char **argv)93 readcmd(shinstance *psh, int argc, char **argv) 92 94 { 93 95 char **ap; … … 107 109 while ((i = nextopt(psh, "p:r")) != '\0') { 108 110 if (i == 'p') 109 prompt = optionarg;111 prompt = psh->optionarg; 110 112 else 111 113 rflag = 1; … … 214 216 215 217 int 216 umaskcmd( int argc, char **argv)218 umaskcmd(shinstance *psh, int argc, char **argv) 217 219 { 218 220 char *ap; … … 354 356 355 357 int 356 ulimitcmd( int argc, char **argv)358 ulimitcmd(shinstance *psh, int argc, char **argv) 357 359 { 358 360 int c; … … 418 420 out1fmt(psh, "%-20s ", l->name); 419 421 if (val == RLIM_INFINITY) 420 out1fmt( "unlimited\n");422 out1fmt(psh, "unlimited\n"); 421 423 else 422 424 { 423 425 val /= l->factor; 424 #ifdef BSD4_4425 426 out1fmt(psh, "%lld\n", (long long) val); 426 #else427 out1fmt(psh, "%ld\n", (long) val);428 #endif429 427 } 430 428 } … … 451 449 { 452 450 val /= l->factor; 453 #ifdef BSD4_4454 451 out1fmt(psh, "%lld\n", (long long) val); 455 #else456 out1fmt(psh, "%ld\n", (long) val);457 #endif458 452 } 459 453 } -
trunk/src/kash/win/mscfakes.h
r881 r1204 197 197 //int sigwait(const sigset_t *, int *); 198 198 int siginterrupt(int, int); 199 #undef setmode 200 void * setmode(const char *p); 201 mode_t getmode(const void *bbox, mode_t omode); 199 202 200 203 #endif /* _MSC_VER */ -
trunk/src/kash/win/sys/resource.h
r819 r1204 101 101 #define RLIM_NLIMITS 12 /* number of resource limits */ /* bird: was 11 */ 102 102 103 #define RLIM_INFINITY ( ((rlim_t)1 << 63) - 1)103 #define RLIM_INFINITY (0x7fffffffffffffffLL) 104 104 /* XXX Missing: RLIM_SAVED_MAX, RLIM_SAVED_CUR */ 105 105 … … 135 135 /* XXX 2nd arg to [gs]etpriority() should be an id_t */ 136 136 //int getpriority(int, /*int*/ id_t); /* bird: SuS uses id_t */ 137 //int getrlimit(int, struct rlimit *);137 int getrlimit(int, struct rlimit *); 138 138 int getrusage(int, struct rusage *); 139 139 //int setpriority(int, /*int*/ id_t, int); /* bird: SuS uses id_t */
Note:
See TracChangeset
for help on using the changeset viewer.