MCPcopy Create free account
hub / github.com/boostorg/build / file_query

Function file_query

v2/engine/filesys.c:178–206  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

176 */
177
178file_info_t * file_query( OBJECT * const path )
179{
180 /* FIXME: Add tracking for disappearing files (i.e. those that can not be
181 * detected by stat() even though they had been detected successfully
182 * before) and see how they should be handled in the rest of Boost Jam code.
183 * Possibly allow Jamfiles to specify some files as 'volatile' which would
184 * make Boost Jam avoid caching information about those files and instead
185 * ask the OS about them every time.
186 */
187 int found;
188 file_info_t * const ff = file_info( path, &found );
189 if ( !found )
190 {
191 file_query_( ff );
192 if ( ff->exists )
193 {
194 /* Set the path's timestamp to 1 in case it is 0 or undetected to avoid
195 * confusion with non-existing paths.
196 */
197 if ( timestamp_empty( &ff->time ) )
198 timestamp_init( &ff->time, 1, 0 );
199 }
200 }
201 if ( !ff->exists )
202 {
203 return 0;
204 }
205 return ff;
206}
207
208
209/*

Callers 8

file_is_fileFunction · 0.85
file_timeFunction · 0.85
file_dirscan_implFunction · 0.85
append_if_existsFunction · 0.85
searchFunction · 0.85
file_query_Function · 0.85
path_existsFunction · 0.85

Calls 4

file_infoFunction · 0.85
timestamp_emptyFunction · 0.85
timestamp_initFunction · 0.85
file_query_Function · 0.70

Tested by

no test coverage detected