|
FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
|
Go to the documentation of this file.
43 #include <sys/types.h>
51 u8 * file_name),
void *arg,
59 d = opendir (dir_name);
75 if (e->d_type == DT_DIR
76 && (!strncmp (e->d_name,
".", 1) ||
77 !strncmp (e->d_name,
"..", 2)))
82 if (e->d_type == DT_DIR)
86 s =
format (s,
"%s/%s", dir_name, e->d_name);
87 t =
format (t,
"%s", e->d_name);
114 if ((mkdir (
c, 0755)) && (errno != EEXIST))
125 if ((mkdir (
path, 0755)) && (errno != EEXIST))
139 const char *
path,
u8 ** full_path)
142 char *last_slash = 0;
148 else if (strncmp (
path,
"../", 3) == 0 || strstr (
path,
"/../"))
152 else if (
path[0] ==
'/')
159 "file %s is not in runtime directory %s",
171 if ((last_slash = strrchr ((
char *) fp,
'/')) != NULL)
176 if (last_slash != NULL)
#define clib_error_return(e, args...)
clib_error_t * foreach_directory_file(char *dir_name, clib_error_t *(*f)(void *arg, u8 *path_name, u8 *file_name), void *arg, int scan_dirs)
clib_error_t * vlib_unix_validate_runtime_file(unix_main_t *um, const char *path, u8 **full_path)
#define vec_add1(V, E)
Add 1 element to end of vector (unspecified alignment).
sll srl srl sll sra u16x4 i
#define vec_free(V)
Free vector's memory (no header).
description fragment has unexpected format
#define clib_error_return_unix(e, args...)
clib_error_t * vlib_unix_recursive_mkdir(char *path)