Mercurial > dovecot > core-2.2
annotate src/lib/abspath.h @ 23007:36e01285b5b8
lib: buffer - Improve header comment for buffer_insert() and buffer_delete().
author | Stephan Bosch <stephan.bosch@dovecot.fi> |
---|---|
date | Mon, 18 Mar 2019 00:52:37 +0100 |
parents | f483bbface26 |
children |
rev | line source |
---|---|
10458 | 1 #ifndef ABSPATH_H |
2 #define ABSPATH_H | |
3 | |
4 /* Returns path as absolute path. If it's not already absolute path, | |
5 it's assumed to be relative to current working directory. */ | |
6 const char *t_abspath(const char *path); | |
7 /* Like t_abspath(), but path is relative to given root. */ | |
8 const char *t_abspath_to(const char *path, const char *root); | |
9 | |
10502
13be6ac759ee
Added t_get_current_dir() and use it instead of getcwd().
Timo Sirainen <tss@iki.fi>
parents:
10458
diff
changeset
|
10 /* Returns current directory, allocated from data stack. */ |
13be6ac759ee
Added t_get_current_dir() and use it instead of getcwd().
Timo Sirainen <tss@iki.fi>
parents:
10458
diff
changeset
|
11 int t_get_current_dir(const char **dir_r); |
10571 | 12 /* Returns symlink destination, allocated from data stack. */ |
13 int t_readlink(const char *path, const char **dest_r); | |
10502
13be6ac759ee
Added t_get_current_dir() and use it instead of getcwd().
Timo Sirainen <tss@iki.fi>
parents:
10458
diff
changeset
|
14 |
11001 | 15 /* Update binpath to be absolute: |
16 a) begins with '/' -> no change | |
17 b) contains '/' -> assume relative to working directory | |
18 c) set to first executable that's found from $PATH | |
19 | |
20 If no usable binary was found, return FALSE. */ | |
21 bool t_binary_abspath(const char **binpath); | |
22 | |
10458 | 23 #endif |