Mercurial > hg > xemacs-beta
comparison src/dired.c @ 707:a307f9a2021d
[xemacs-hg @ 2001-12-20 05:49:28 by andyp]
sync with 21-4-6-windows
author | andyp |
---|---|
date | Thu, 20 Dec 2001 05:49:48 +0000 |
parents | fdefd0186b75 |
children | 336a418893b5 |
comparison
equal
deleted
inserted
replaced
706:c9bf82d465b5 | 707:a307f9a2021d |
---|---|
809 } | 809 } |
810 else | 810 else |
811 return Qnil; | 811 return Qnil; |
812 } | 812 } |
813 | 813 |
814 #if 0 | |
815 /* ... never used ... should use list2 directly anyway ... */ | |
816 /* NOTE: This function can never return a negative value. */ | |
814 Lisp_Object | 817 Lisp_Object |
815 wasteful_word_to_lisp (unsigned int item) | 818 wasteful_word_to_lisp (unsigned int item) |
816 { | 819 { |
817 /* Compatibility: in other versions, file-attributes returns a LIST | 820 /* Compatibility: in other versions, file-attributes returns a LIST |
818 of two 16 bit integers... */ | 821 of two 16 bit integers... */ |
819 Lisp_Object cons = word_to_lisp (item); | 822 Lisp_Object cons = word_to_lisp (item); |
820 XCDR (cons) = Fcons (XCDR (cons), Qnil); | 823 XCDR (cons) = Fcons (XCDR (cons), Qnil); |
821 return cons; | 824 return cons; |
822 } | 825 } |
826 #endif | |
823 | 827 |
824 DEFUN ("file-attributes", Ffile_attributes, 1, 1, 0, /* | 828 DEFUN ("file-attributes", Ffile_attributes, 1, 1, 0, /* |
825 Return a list of attributes of file FILENAME. | 829 Return a list of attributes of file FILENAME. |
826 Value is nil if specified file cannot be opened. | 830 Value is nil if specified file cannot be opened. |
827 Otherwise, list elements are: | 831 Otherwise, list elements are: |
904 #endif | 908 #endif |
905 } | 909 } |
906 values[1] = make_int (s.st_nlink); | 910 values[1] = make_int (s.st_nlink); |
907 values[2] = make_int (s.st_uid); | 911 values[2] = make_int (s.st_uid); |
908 values[3] = make_int (s.st_gid); | 912 values[3] = make_int (s.st_gid); |
909 values[4] = wasteful_word_to_lisp (s.st_atime); | 913 values[4] = make_time (s.st_atime); |
910 values[5] = wasteful_word_to_lisp (s.st_mtime); | 914 values[5] = make_time (s.st_mtime); |
911 values[6] = wasteful_word_to_lisp (s.st_ctime); | 915 values[6] = make_time (s.st_ctime); |
912 values[7] = make_int ((EMACS_INT) s.st_size); | 916 values[7] = make_int ((EMACS_INT) s.st_size); |
913 /* If the size is out of range, give back -1. */ | 917 /* If the size is out of range, give back -1. */ |
914 /* #### Fix when Emacs gets bignums! */ | 918 /* #### Fix when Emacs gets bignums! */ |
915 if (XINT (values[7]) != s.st_size) | 919 if (XINT (values[7]) != s.st_size) |
916 values[7] = make_int (-1); | 920 values[7] = make_int (-1); |