utilvfs.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef MC_VFS_UTILVFS_H
  2. #define MC_VFS_UTILVFS_H
  3. #include <sys/stat.h>
  4. /* Flags for vfs_split_url() */
  5. #define URL_ALLOW_ANON 1
  6. #define URL_NOSLASH 2
  7. int vfs_finduid (const char *name);
  8. int vfs_findgid (const char *name);
  9. char *vfs_split_url (const char *path, char **host, char **user, int *port,
  10. char **pass, int default_port, int flags);
  11. int vfs_split_text (char *p);
  12. int vfs_mkstemps (char **pname, const char *prefix, const char *basename);
  13. void vfs_die (const char *msg);
  14. char *vfs_get_password (const char *msg);
  15. gboolean vfs_parse_filetype (const char *s, size_t *ret_skipped,
  16. mode_t *ret_type);
  17. gboolean vfs_parse_fileperms (const char *s, size_t *ret_skipped,
  18. mode_t *ret_perms);
  19. gboolean vfs_parse_filemode (const char *s, size_t *ret_skipped,
  20. mode_t *ret_mode);
  21. gboolean vfs_parse_raw_filemode (const char *s, size_t *ret_skipped,
  22. mode_t *ret_mode);
  23. int vfs_parse_ls_lga (const char *p, struct stat *s, char **filename,
  24. char **linkname);
  25. int vfs_parse_filedate (int idx, time_t *t);
  26. #endif