mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-10 21:42:00 +03:00
VFS: added non-vfs version of vfs_get_encoding()
This commit is contained in:
parent
e2e490a054
commit
2153b3c5cd
13
vfs/vfs.h
13
vfs/vfs.h
@ -24,6 +24,10 @@ int mc_utime (const char *path, struct utimbuf *times);
|
||||
int mc_readlink (const char *path, char *buf, int bufsiz);
|
||||
int mc_ungetlocalcopy (const char *pathname, const char *local, int has_changed);
|
||||
|
||||
/* return encoding after last #enc: or NULL, if part does not contain #enc:
|
||||
* return static buffer */
|
||||
const char *vfs_get_encoding (const char *path);
|
||||
|
||||
#else /* USE_VFS */
|
||||
|
||||
#define vfs_init() do { } while (0)
|
||||
@ -36,6 +40,12 @@ int mc_ungetlocalcopy (const char *pathname, const char *local, int has_changed)
|
||||
#define mc_readlink readlink
|
||||
#define mc_ungetlocalcopy(x,y,z) do { } while (0)
|
||||
|
||||
static inline const char *vfs_get_encoding (const char *path)
|
||||
{
|
||||
(void) path;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
#endif /* USE_VFS */
|
||||
|
||||
char *vfs_strip_suffix_from_filename (const char *filename);
|
||||
@ -48,9 +58,6 @@ char *vfs_get_current_dir (void);
|
||||
char *vfs_translate_path (const char *path);
|
||||
/* return new string */
|
||||
char *vfs_translate_path_n (const char *path);
|
||||
/* return encoding after last #enc: or NULL, if part does not contain #enc:
|
||||
* return static buffer */
|
||||
const char *vfs_get_encoding (const char *path);
|
||||
/* canonize and translate path, return new string */
|
||||
char *vfs_canon_and_translate (const char *path);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user