mirror of
https://github.com/Interlisp/maiko.git
synced 2026-03-03 18:06:23 +00:00
Adds GETFILEATTRIBUTE processing for INODE_LO and INODE_HI attributes.
This commit is contained in:
@@ -35,6 +35,8 @@
|
||||
#define PROTECTION (S_POSITIVE | 6)
|
||||
#define EOL (S_POSITIVE | 7)
|
||||
#define ALL (S_POSITIVE | 8)
|
||||
#define INODE_LO (S_POSITIVE | 9)
|
||||
#define INODE_HI (S_POSITIVE | 10)
|
||||
|
||||
#define ToLispTime(x) ((int)(x) + 29969152)
|
||||
/* For getfileinfo. For WDATE&RDATE */
|
||||
|
||||
11
src/dsk.c
11
src/dsk.c
@@ -1528,7 +1528,8 @@ LispPTR DSK_directorynamep(LispPTR *args)
|
||||
*
|
||||
* Value: If failed, returns Lisp NIL. If succeed, returned value is
|
||||
* different according to the attribute requested.
|
||||
* In the case of LENGTH, WDATE, RDATE, and PROTECTION, returns Lisp T.
|
||||
* In the case of LENGTH, WDATE, RDATE, and PROTECTION, INODE_LO, and
|
||||
INODE_HI, returns Lisp T.
|
||||
* In the case of AUTHOR and ALL, returns the length of the author name
|
||||
* copied into the specified buffer.
|
||||
*
|
||||
@@ -1672,6 +1673,14 @@ LispPTR COM_getfileinfo(LispPTR *args)
|
||||
#endif /* DOS */
|
||||
return (GetPosSmallp(len));
|
||||
}
|
||||
case INODE_HI:
|
||||
bufp = (unsigned *)NativeAligned4FromLAddr(args[2]);
|
||||
*bufp = ((uint64_t)sbuf.st_ino) >> 32;
|
||||
return (ATOM_T);
|
||||
case INODE_LO:
|
||||
bufp = (unsigned *)NativeAligned4FromLAddr(args[2]);
|
||||
*bufp = ((uint64_t)sbuf.st_ino) & 0xffffffff;
|
||||
return (ATOM_T);
|
||||
case ALL: {
|
||||
/*
|
||||
* The format of the buffer which has been allocated by Lisp
|
||||
|
||||
Reference in New Issue
Block a user