
Data Structures | |
| struct | xml_entity_s |
Defines | |
| #define | INSERT_STRING(string) |
| #define | INSERT_STRING_NO_FREE(string) |
| #define | SMB_SCHEME "smb" |
Functions | |
| char * | decode_URI_duplicate (const char *psz) |
| Decode encoded URI component. | |
| char * | decode_URI (char *psz) |
| Decode an encoded URI component in place. | |
| static bool | isurisafe (int c) |
| static char * | encode_URI_bytes (const char *psz_uri, size_t len) |
| char * | encode_URI_component (const char *psz_uri) |
| Encodes an URI component (RFC3986 §2). | |
| static int | cmp_entity (const void *key, const void *elem) |
| void | resolve_xml_special_chars (char *psz_value) |
| Converts "<", ">" and "&" to "<", ">" and "&". | |
| char * | convert_xml_special_chars (const char *psz_content) |
| Converts '<', '>', '\"', '\'' and '&' to their html entities. | |
| char * | vlc_b64_encode_binary (const uint8_t *src, size_t i_src) |
| char * | vlc_b64_encode (const char *src) |
| size_t | vlc_b64_decode_binary_to_buffer (uint8_t *p_dst, size_t i_dst, const char *p_src) |
| size_t | vlc_b64_decode_binary (uint8_t **pp_dst, const char *psz_src) |
| char * | vlc_b64_decode (const char *psz_src) |
| char * | str_format_time (const char *tformat) |
| Formats current time into a heap-allocated string. | |
| char * | str_format_meta (vlc_object_t *p_object, const char *string) |
| char * | str_format (vlc_object_t *p_this, const char *psz_src) |
| Apply str format time and str format meta. | |
| void | filename_sanitize (char *str) |
| Remove forbidden characters from filenames (including slashes). | |
| void | path_sanitize (char *str) |
| Remove forbidden characters from full paths (leaves slashes). | |
| char * | make_URI (const char *path) |
| Convert a file path to an URI. | |
| char * | make_path (const char *url) |
| Tries to convert an URI to a local (UTF-8-encoded) file path. | |
Variables | |
| static struct xml_entity_s | xml_entities [] |
| #define INSERT_STRING | ( | string | ) |
| #define INSERT_STRING_NO_FREE | ( | string | ) |
Value:
{ \
int len = strlen( string ); \
dst = xrealloc( dst, i_size = i_size + len );\
memcpy( dst+d, string, len ); \
d += len; \
}
Referenced by str_format_meta().
| #define SMB_SCHEME "smb" |
Referenced by make_URI().
| static int cmp_entity | ( | const void * | key, | |
| const void * | elem | |||
| ) | [static] |
| char* decode_URI | ( | char * | psz | ) |
Decode an encoded URI component in place.
This function does NOT decode entire URIs. It decodes components (e.g. host name, directory, file name). Decoded URIs do not exist in the real world (see RFC3986 §2.4). Complete URIs are always "encoded" (or they are syntaxically invalid).
Note that URI encoding is different from Javascript escaping. Especially, white spaces and Unicode non-ASCII code points are encoded differently.
Referenced by decode_URI_duplicate(), EvaluateRPN(), input_item_SetURI(), MacroDo(), make_path(), Open(), parseURL(), vlc_UrlParse(), and vlclua_decode_uri().
| char* decode_URI_duplicate | ( | const char * | psz | ) |
Decode encoded URI component.
See also decode_URI().
References decode_URI(), and strdup().
Referenced by Demux(), Open(), ParseClipInfo(), Port_finder(), ReadMeta(), and test_decode().
| static char* encode_URI_bytes | ( | const char * | psz_uri, | |
| size_t | len | |||
| ) | [static] |
| char* encode_URI_component | ( | const char * | psz_uri | ) |
Encodes an URI component (RFC3986 §2).
| psz_uri | nul-terminated UTF-8 representation of the component. Obviously, you can't pass an URI containing a nul character, but you don't want to do that, do you? |
References encode_URI_bytes().
Referenced by DirBlock(), EvaluateRPN(), ProcessMRL(), and vlclua_encode_uri_component().
| static bool isurisafe | ( | int | c | ) | [inline, static] |
Referenced by encode_URI_bytes().
| char* make_path | ( | const char * | url | ) |
Tries to convert an URI to a local (UTF-8-encoded) file path.
| url | URI to convert |
References asprintf(), decode_URI(), DIR_SEP, DIR_SEP_CHAR, strdup(), strncasecmp(), strndup(), and unlikely.
Referenced by ArtCallback(), InputManager::decodeArtURL(), FindMeta(), get_path(), input_item_WriteMeta(), ItemChange(), SDPHandleUrl(), subtitles_Detect(), and MetaPanel::update().
| char* make_URI | ( | const char * | path | ) |
Convert a file path to an URI.
If already an URI, return a copy of the string. path path to convert (or URI to copy)
References asprintf(), DIR_SEP, DIR_SEP_CHAR, encode_URI_bytes(), getcwd(), i, make_URI(), SMB_SCHEME, and strdup().
Referenced by DirInit(), MainInterface::dropEventPlay(), CmdAddItem::execute(), FileBitmap::FileBitmap(), FindMeta(), GetFilenames(), libvlc_media_new_path(), make_URI(), onNewFileAdded(), VLCOpen::openFilePathChanged:, playlist_FindArtInCache(), playlist_Import(), playlist_MLLoad(), playlist_SaveArt(), DialogsProvider::playMRL(), ProcessMRL(), Run(), SubtitleAdd(), test_current_directory_path(), test_path(), and XMLParser::XMLParser().
struct xml_entity_s xml_entities[] [static] |
Referenced by resolve_xml_special_chars().
1.5.6