Crossfire Server, Branches 1.12
R18729
|
#include <assert.h>
#include <stdio.h>
#include <string.h>
#include <global.h>
#include "define.h"
#include "path.h"
Go to the source code of this file.
Functions | |
char * | path_combine (const char *src, const char *dst, char *path, size_t size) |
char * | path_combine_and_normalize (const char *src, const char *dst, char *path, size_t size) |
void | path_normalize (char *path) |
Contains file path manipulation functions.
Definition in file path.c.
char* path_combine | ( | const char * | src, |
const char * | dst, | ||
char * | path, | ||
size_t | size | ||
) |
Combines 2 paths, which can be relative.
src | path we're starting from. |
dst | path we're doing to. |
path | buffer containing the combined path. |
size | size of path. |
Definition at line 63 of file path.c.
References llevDebug, LOG(), and snprintf().
Referenced by check_combine(), and path_combine_and_normalize().
char* path_combine_and_normalize | ( | const char * | src, |
const char * | dst, | ||
char * | path, | ||
size_t | size | ||
) |
Combines the 2 paths.
src | path we're starting from. |
dst | path we're getting to. |
path | buffer that will contain combined paths. |
size | length of path. |
Definition at line 184 of file path.c.
References path_combine(), and path_normalize().
Referenced by check_combine_and_normalize(), command_reset(), enter_exit(), enter_fixed_template_map(), enter_random_template_map(), enter_unique_map(), load_and_link_tiled_map(), load_map_header(), and process_map().
void path_normalize | ( | char * | path | ) |
Cleans specified path. Removes .. and things like that.
path | path to clear. It will be modified in place. |
Definition at line 97 of file path.c.
References llevDebug, and LOG().
Referenced by check_normalize(), and path_combine_and_normalize().