Mercurial > octave-nkf
comparison liboctave/file-stat.cc @ 8690:6e9887f9cf9f
file-stat.cc: use EXISTS instead of OK in previuos change
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 05 Feb 2009 19:39:38 -0500 |
parents | ddbe87599331 |
children | eb63fbe60fab |
comparison
equal
deleted
inserted
replaced
8689:ddbe87599331 | 8690:6e9887f9cf9f |
---|---|
52 // initialized, they should throw an exception. | 52 // initialized, they should throw an exception. |
53 | 53 |
54 bool | 54 bool |
55 base_file_stat::is_blk (void) const | 55 base_file_stat::is_blk (void) const |
56 { | 56 { |
57 return ok () && is_blk (fs_mode); | 57 return exists () && is_blk (fs_mode); |
58 } | 58 } |
59 | 59 |
60 bool | 60 bool |
61 base_file_stat::is_chr (void) const | 61 base_file_stat::is_chr (void) const |
62 { | 62 { |
63 return ok () && is_chr (fs_mode); | 63 return exists () && is_chr (fs_mode); |
64 } | 64 } |
65 | 65 |
66 bool | 66 bool |
67 base_file_stat::is_dir (void) const | 67 base_file_stat::is_dir (void) const |
68 { | 68 { |
69 return ok () && is_dir (fs_mode); | 69 return exists () && is_dir (fs_mode); |
70 } | 70 } |
71 | 71 |
72 bool | 72 bool |
73 base_file_stat::is_fifo (void) const | 73 base_file_stat::is_fifo (void) const |
74 { | 74 { |
75 return ok () && is_fifo (fs_mode); | 75 return exists () && is_fifo (fs_mode); |
76 } | 76 } |
77 | 77 |
78 bool | 78 bool |
79 base_file_stat::is_lnk (void) const | 79 base_file_stat::is_lnk (void) const |
80 { | 80 { |
81 return ok () && is_lnk (fs_mode); | 81 return exists () && is_lnk (fs_mode); |
82 } | 82 } |
83 | 83 |
84 bool | 84 bool |
85 base_file_stat::is_reg (void) const | 85 base_file_stat::is_reg (void) const |
86 { | 86 { |
87 return ok () && is_reg (fs_mode); | 87 return exists () && is_reg (fs_mode); |
88 } | 88 } |
89 | 89 |
90 bool | 90 bool |
91 base_file_stat::is_sock (void) const | 91 base_file_stat::is_sock (void) const |
92 { | 92 { |
93 return ok () && is_sock (fs_mode); | 93 return exists () && is_sock (fs_mode); |
94 } | 94 } |
95 | 95 |
96 bool | 96 bool |
97 base_file_stat::is_blk (mode_t mode) | 97 base_file_stat::is_blk (mode_t mode) |
98 { | 98 { |