VLC  3.0.15
vlc_getopt.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Declarations for getopt_long()
3  *****************************************************************************
4  * Copyright (C) 1987-1997 Free Software Foundation, Inc.
5  * Copyright (C) 2005-2010 VLC authors and VideoLAN
6  *
7  * This program is free software; you can redistribute it and/or modify it
8  * under the terms of the GNU Lesser General Public License as published by
9  * the Free Software Foundation; either version 2.1 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU Lesser General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public License
18  * along with this program; if not, write to the Free Software Foundation,
19  * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
20  *****************************************************************************/
21 
22 #ifndef VLC_GETOPT_H
23 #define VLC_GETOPT_H 1
24 
25 typedef struct vlc_getopt_s
26 {
27 /* For communication from `getopt' to the caller.
28  When `getopt' finds an option that takes an argument,
29  the argument value is returned here. */
30 
31  char *arg;
32 
33 /* Index in ARGV of the next element to be scanned.
34  This is used for communication to and from the caller
35  and for communication between successive calls to `getopt'.
36 
37  On entry to `getopt', zero means this is the first call; initialize.
38 
39  When `getopt' returns -1, this is the index of the first of the
40  non-option elements that the caller should itself scan.
41 
42  Otherwise, `optind' communicates from one call to the next
43  how much of ARGV has been scanned so far. */
44 
45  int ind;
46 
47 /* Set to an option character which was unrecognized. */
48 
49  int opt;
50 
51 /* The next char to be scanned in the option-element
52  in which the last option character we returned was found.
53  This allows us to pick up the scan where we left off.
54 
55  If this is zero, or a null string, it means resume the scan
56  by advancing to the next ARGV-element. */
57 
58  char *nextchar;
59 
60 /* Handle permutation of arguments. */
61 
62 /* Describe the part of ARGV that contains non-options that have
63  been skipped. `first_nonopt' is the index in ARGV of the first of them;
64  `last_nonopt' is the index after the last of them. */
65 
67  int last_nonopt;
68 
69 } vlc_getopt_t;
70 
71 /* Describe the long-named options requested by the application.
72  The LONG_OPTIONS argument to getopt_long or getopt_long_only is a vector
73  of `struct option' terminated by an element containing a name which is
74  zero.
75 
76  The field `has_arg' is:
77  false if the option does not take an argument,
78  true if the option requires an argument.
79 
80  If the field `flag' is not NULL, it points to a variable that is set
81  to the value given in the field `val' when the option is found, but
82  left unchanged if the option is not found.
83 
84  To have a long-named option do something other than set an `int' to
85  a compiled-in constant, such as set a value from `optarg', set the
86  option's `flag' field to zero and its `val' field to a nonzero
87  value (the equivalent single-letter option character, if there is
88  one). For long options that have a zero `flag' field, `getopt'
89  returns the contents of the `val' field. */
90 
91 struct vlc_option
92 {
93  const char *name;
94  bool has_arg;
95  int *flag;
96  int val;
97 };
98 
99 extern int vlc_getopt_long(int argc, char *const *argv, const char *shortopts,
100  const struct vlc_option *longopts, int *longind,
101  vlc_getopt_t *restrict state);
102 
103 #endif /* VLC_GETOPT_H */
module_config_t::psz_name
const char * psz_name
Definition: vlc_configuration.h:71
psz_vlc_changeset
const char psz_vlc_changeset[]
VLC_HOME_DIR
Definition: vlc_configuration.h:121
vlc_getopt.h
vlc_option::name
const char * name
Definition: vlc_getopt.h:92
vlc_http_res_init
int vlc_http_res_init(struct vlc_http_resource *restrict res, const struct vlc_http_resource_cbs *cbs, struct vlc_http_mgr *mgr, const char *uri, const char *ua, const char *ref)
Definition: resource.c:179
count
size_t count
Definition: core.c:461
exchange
static void exchange(char **argv, vlc_getopt_t *restrict state)
Definition: getopt.c:40
BLUE
#define BLUE
Definition: help.c:236
print_help_on_full_help
static void print_help_on_full_help(void)
Definition: help.c:159
vlc_fopen
FILE * vlc_fopen(const char *filename, const char *mode)
Opens a FILE pointer.
Definition: filesystem.c:46
PADDING_SPACES
#define PADDING_SPACES
Definition: help.c:242
i_value
uint32_t i_value
Definition: vlc_text_style.h:215
atof
double atof(const char *)
confnamecmp
static int confnamecmp(const void *key, const void *elem)
Definition: core.c:451
var_SetBool
#define var_SetBool(a, b, c)
Definition: vlc_variables.h:257
OPTION_VALUE_SEP
#define OPTION_VALUE_SEP
module_list_get
module_t ** module_list_get(size_t *n)
Gets the flat list of VLC modules.
Definition: bank.c:699
vlc_http_file_can_seek
bool vlc_http_file_can_seek(struct vlc_http_resource *res)
Checks seeking support.
Definition: file.c:195
MAGENTA
#define MAGENTA
Definition: help.c:237
vlc_getopt_long
int vlc_getopt_long(int argc, char *const *argv, const char *optstring, const struct vlc_option *restrict longopts, int *longind, vlc_getopt_t *restrict state)
Definition: getopt.c:145
vlc_http_res_open
struct vlc_http_msg * vlc_http_res_open(struct vlc_http_resource *res, void *opaque)
Definition: resource.c:83
LINE_START
#define LINE_START
Definition: help.c:241
vlc_common.h
CONFIG_ITEM_FLOAT
#define CONFIG_ITEM_FLOAT
Definition: vlc_plugin.h:120
module_t::pp_shortcuts
const char ** pp_shortcuts
Definition: modules.h:86
var_CreateGetNonEmptyString
#define var_CreateGetNonEmptyString(a, b)
Definition: vlc_variables.h:496
CONFIG_ITEM_STRING
#define CONFIG_ITEM_STRING
Definition: vlc_plugin.h:124
module_config_t::psz_text
const char * psz_text
Definition: vlc_configuration.h:72
ConsoleWidth
static unsigned ConsoleWidth(void)
Returns the console width or a best guess.
Definition: help.c:65
VLC_CompileHost
const char * VLC_CompileHost(void)
Definition: version.c:42
module_get_object
const char * module_get_object(const module_t *m)
Get the internal name of a module.
Definition: modules.c:63
DIR_SEP
#define DIR_SEP
Definition: vlc_common.h:1023
VLC_CompileBy
const char * VLC_CompileBy(void)
Definition: version.c:41
module_config_t::list_text
const char ** list_text
Definition: vlc_configuration.h:89
vlc_http_file_callbacks
static const struct vlc_http_resource_cbs vlc_http_file_callbacks
Definition: file.c:106
module_gettext
const char * module_gettext(const module_t *m, const char *str)
Translate a string using the module's text domain.
Definition: modules.c:127
IsConfigIntegerType
#define IsConfigIntegerType(type)
Definition: configuration.h:47
vlc_getopt_s::opt
int opt
Definition: vlc_getopt.h:66
block_t::i_buffer
size_t i_buffer
Payload length.
Definition: vlc_block.h:116
msg_Info
#define msg_Info(p_this,...)
Definition: vlc_messages.h:80
vlc_plugin_t
VLC plugin.
Definition: modules.h:32
uselocale
static locale_t uselocale(locale_t loc)
Definition: vlc_fixups.h:356
vlc_swidth
static int vlc_swidth(const char *str)
Definition: help.c:325
vlc_http_msg_destroy
void vlc_http_msg_destroy(struct vlc_http_msg *m)
Destroys an HTTP message.
Definition: message.c:191
config_GetType
int config_GetType(const char *psz_name)
Definition: core.c:52
module_config_t::i
const int * i
Definition: vlc_configuration.h:85
locale_t
void * locale_t
Definition: vlc_fixups.h:341
print_section
static void print_section(const module_t *m, const module_config_t **sect, bool color, bool desc)
Definition: help.c:244
module_t::i_shortcuts
unsigned i_shortcuts
Shortcuts to the module.
Definition: modules.h:85
Usage
static void Usage(vlc_object_t *, const char *)
Definition: help.c:582
module_config_t::orig
module_value_t orig
Definition: vlc_configuration.h:76
module_list_free
void module_list_free(module_t **list)
Frees the flat list of VLC modules.
Definition: bank.c:688
vlc_mkdir
int vlc_mkdir(const char *dirname, mode_t mode)
Creates a directory.
Definition: filesystem.c:93
vlc_http_resource::response
struct vlc_http_msg * response
Definition: resource.h:45
var_InheritBool
#define var_InheritBool(o, n)
Definition: vlc_variables.h:601
vlc_http_mgr
Definition: connmgr.c:95
vlc_charset.h
VLC_VAR_BOOL
#define VLC_VAR_BOOL
Definition: vlc_variables.h:49
CONFIG_SECTION
#define CONFIG_SECTION
Definition: vlc_plugin.h:117
config_UnsortConfig
void config_UnsortConfig(void)
Definition: core.c:501
module_value_t::psz
char * psz
Definition: vlc_configuration.h:50
vlc_common_members::libvlc
libvlc_int_t * libvlc
LibVLC instance.
Definition: vlc_common.h:441
config_GetInt
int64_t config_GetInt(vlc_object_t *p_this, const char *psz_name)
Definition: core.c:90
msg_Dbg
#define msg_Dbg(p_this,...)
Definition: vlc_messages.h:86
xstrdup
static char * xstrdup(const char *str)
Definition: vlc_common.h:994
vlc_http_file_get_size
uintmax_t vlc_http_file_get_size(struct vlc_http_resource *res)
Gets file size.
Definition: file.c:177
config_GetPsz
char * config_GetPsz(vlc_object_t *p_this, const char *psz_name)
Definition: core.c:151
_
#define _(str)
Definition: vlc_fixups.h:371
vlc_getopt_s::ind
int ind
Definition: vlc_getopt.h:62
vlc_option::has_arg
bool has_arg
Definition: vlc_getopt.h:93
VLC_EGENERIC
#define VLC_EGENERIC
Unspecified error.
Definition: vlc_common.h:350
IsConfigStringType
#define IsConfigStringType(type)
Definition: configuration.h:45
module_config_t::i_cb
vlc_integer_list_cb i_cb
Definition: vlc_configuration.h:87
config_FindConfig
module_config_t * config_FindConfig(const char *name)
Definition: core.c:514
vlc_towc
size_t vlc_towc(const char *str, uint32_t *restrict pwc)
Decodes a code point from UTF-8.
Definition: unicode.c:111
VLC_Compiler
const char * VLC_Compiler(void)
Definition: version.c:43
CONFIG_CLASS
#define CONFIG_CLASS(x)
Definition: configuration.h:43
VLC_VAR_INTEGER
#define VLC_VAR_INTEGER
Definition: vlc_variables.h:50
VLC_VAR_STRING
#define VLC_VAR_STRING
Definition: vlc_variables.h:51
getenv
static char * getenv(const char *name)
Definition: vlc_fixups.h:293
freelocale
static void freelocale(locale_t loc)
Definition: vlc_fixups.h:343
VLC_VAR_FLOAT
#define VLC_VAR_FLOAT
Definition: vlc_variables.h:52
vlc_option::val
int val
Definition: vlc_getopt.h:95
config_GetPsz
#define config_GetPsz(a, b)
Definition: vlc_configuration.h:146
resource.h
var_InheritString
#define var_InheritString(o, n)
Definition: vlc_variables.h:639
vlc_rwlock_unlock
void vlc_rwlock_unlock(vlc_rwlock_t *lock)
Releases a read/write lock.
Definition: thread.c:393
vlc_http_msg_add_header
int vlc_http_msg_add_header(struct vlc_http_msg *m, const char *name, const char *fmt,...)
Definition: message.c:142
vlc_gettext
char * vlc_gettext(const char *msgid)
In-tree plugins share their gettext domain with LibVLC.
Definition: textdomain.c:89
asprintf
int asprintf(char **, const char *,...)
config_dirty
bool config_dirty
Definition: core.c:41
config_RemoveIntf
void config_RemoveIntf(vlc_object_t *p_this, const char *psz_intf)
Definition: intf.c:85
var_Create
#define var_Create(a, b, c)
Definition: vlc_variables.h:121
config_GetConfigFile
static char * config_GetConfigFile(vlc_object_t *obj)
Get the user's configuration file.
Definition: file.c:58
vlc_getopt_s::nextchar
char * nextchar
Definition: vlc_getopt.h:75
vlc_getopt_s::last_nonopt
int last_nonopt
Definition: vlc_getopt.h:84
vlc_http_file_resp
static int vlc_http_file_resp(const struct vlc_http_resource *res, const struct vlc_http_msg *resp, void *opaque)
Definition: file.c:77
vlc_getopt_s::arg
char * arg
Definition: vlc_getopt.h:48
VLC_CONFIG_DIR
Definition: vlc_configuration.h:122
lock
static vlc_mutex_t lock
Definition: interface.c:62
vlc_ngettext
char * vlc_ngettext(const char *msgid, const char *plural, unsigned long n)
Definition: textdomain.c:98
RED
#define RED
Definition: help.c:233
msg_Warn
#define msg_Warn(p_this,...)
Definition: vlc_messages.h:84
module_t::psz_help
const char * psz_help
Long help string for "special" modules.
Definition: modules.h:93
module_config_t::owner
void * owner
Definition: vlc_configuration.h:91
module_config_t::psz_cb
vlc_string_list_cb psz_cb
Definition: vlc_configuration.h:86
vlc_close
int vlc_close(int fd)
Closes a file descriptor.
Definition: filesystem.c:88
module_Map
int module_Map(vlc_object_t *obj, vlc_plugin_t *plugin)
Definition: bank.c:559
module_t::i_score
int i_score
Score for the capability.
Definition: modules.h:96
vlc_rename
int vlc_rename(const char *oldpath, const char *newpath)
Moves a file atomically.
Definition: filesystem.c:194
vlc_rwlock_wrlock
void vlc_rwlock_wrlock(vlc_rwlock_t *lock)
Acquires a read/write lock for writing.
Definition: thread.c:387
vlc_unlink
int vlc_unlink(const char *filename)
Removes a file.
Definition: filesystem.c:180
vlc_plugins
vlc_plugin_t * vlc_plugins
List of all plug-ins.
Definition: bank.c:101
module_config_t::b_unsaveable
unsigned b_unsaveable
Definition: vlc_configuration.h:66
module_t
Internal module descriptor.
Definition: modules.h:79
message.h
module_config_t::max
module_value_t max
Definition: vlc_configuration.h:78
vlc_http_file_read
block_t * vlc_http_file_read(struct vlc_http_resource *res)
Reads data.
Definition: file.c:231
PauseConsole
#define PauseConsole()
Definition: help.c:54
vlc_open
int vlc_open(const char *filename, int flags,...)
Opens a system file handle.
Definition: filesystem.c:49
f_value
double f_value
Definition: vout_intf.c:81
newlocale
static locale_t newlocale(int mask, const char *locale, locale_t base)
Definition: vlc_fixups.h:347
vlc_strings.h
module_t::psz_longname
const char * psz_longname
Module descriptive name.
Definition: modules.h:92
plugin_show
static bool plugin_show(const vlc_plugin_t *plugin, bool advanced)
Definition: help.c:565
vlc_http_msg_get_token
const char * vlc_http_msg_get_token(const struct vlc_http_msg *msg, const char *field, const char *token)
Looks up a token in a header field.
Definition: message.c:662
vlc_http_file
Definition: file.c:41
getpid
pid_t getpid(void)
var_Destroy
#define var_Destroy(a, b)
Definition: vlc_variables.h:124
config_GetPszChoices
ssize_t config_GetPszChoices(vlc_object_t *obj, const char *name, char ***restrict values, char ***restrict texts)
Determines a list of suggested values for a string configuration item.
Definition: core.c:389
vlc_plugin.h
confcmp
static int confcmp(const void *a, const void *b)
Definition: core.c:444
config_PutPsz
void config_PutPsz(vlc_object_t *p_this, const char *psz_name, const char *psz_value)
Definition: core.c:181
config_IsSafe
bool config_IsSafe(const char *name)
Definition: core.c:77
CONFIG_ITEM_INTEGER
#define CONFIG_ITEM_INTEGER
Definition: vlc_plugin.h:121
Help
static void Help(vlc_object_t *, const char *)
Definition: help.c:199
vlc_http_resource
Definition: resource.h:42
psz_name
const char * psz_name
Definition: vlc_codecs.h:315
Version
static void Version(void)
Definition: help.c:713
vlc_http_file::offset
uintmax_t offset
Definition: file.c:61
strdupnull
static char * strdupnull(const char *src)
Definition: file.c:50
vlc_getopt_long
int vlc_getopt_long(int argc, char *const *argv, const char *shortopts, const struct vlc_option *longopts, int *longind, vlc_getopt_t *restrict state)
vlc_option
Definition: vlc_getopt.h:90
config_PrepareDir
static int config_PrepareDir(vlc_object_t *obj)
Definition: file.c:325
vlc_plugin_t::size
size_t size
Size of items table.
Definition: modules.h:46
modules.h
CYAN
#define CYAN
Definition: help.c:238
vlc_http_file_req
static int vlc_http_file_req(const struct vlc_http_resource *res, struct vlc_http_msg *req, void *opaque)
Definition: file.c:47
config_ListModules
static ssize_t config_ListModules(const char *cap, char ***restrict values, char ***restrict texts)
Definition: core.c:347
vlc_http_file_create
struct vlc_http_resource * vlc_http_file_create(struct vlc_http_mgr *mgr, const char *uri, const char *ua, const char *ref)
Creates an HTTP file.
Definition: file.c:112
vlc_configuration.h
WHITE
#define WHITE
Definition: help.c:239
strdupnull
static char * strdupnull(const char *src)
Definition: core.c:43
config_dirty
bool config_dirty
Definition: core.c:41
vlc_http_error
void *const vlc_http_error
Error pointer value.
Definition: message.c:55
config_CreateDir
int config_CreateDir(vlc_object_t *p_this, const char *psz_dirname)
Definition: file.c:263
vlc_fs.h
module_list_cap
ssize_t module_list_cap(module_t ***restrict list, const char *name)
Builds a sorted list of all VLC modules with a given capability.
Definition: bank.c:732
CONFIG_ITEM_BOOL
#define CONFIG_ITEM_BOOL
Definition: vlc_plugin.h:123
xmalloc
static void * xmalloc(size_t len)
Definition: vlc_common.h:970
NONOPTION_P
#define NONOPTION_P
vlc_plugin_t::items
module_config_t * items
Table of configuration parameters.
Definition: modules.h:45
DIR_SEP_CHAR
#define DIR_SEP_CHAR
Definition: vlc_common.h:1022
config_ResetAll
void config_ResetAll(vlc_object_t *p_this)
Definition: core.c:551
vlc_http_res_get_status
int vlc_http_res_get_status(struct vlc_http_resource *res)
Definition: resource.c:130
vlc_object_t
The main vlc_object_t structure.
Definition: vlc_objects.h:39
IsConfigFloatType
#define IsConfigFloatType(type)
Definition: configuration.h:49
VLC_ENOMEM
#define VLC_ENOMEM
Not enough memory.
Definition: vlc_common.h:351
module_config_t
Definition: vlc_configuration.h:60
module_config_t::b_removed
unsigned b_removed
Definition: vlc_configuration.h:68
VLC_UNUSED
#define VLC_UNUSED(x)
Definition: vlc_common.h:912
module_config_t::psz_type
const char * psz_type
Definition: vlc_configuration.h:70
module_t::psz_capability
const char * psz_capability
Capability.
Definition: modules.h:95
vlc_mutex_t
pthread_mutex_t vlc_mutex_t
Mutex.
Definition: vlc_threads.h:267
VLC_SUCCESS
#define VLC_SUCCESS
No error.
Definition: vlc_common.h:349
config_GetFloat
float config_GetFloat(vlc_object_t *p_this, const char *psz_name)
Definition: core.c:117
config_SaveConfigFile
int config_SaveConfigFile(vlc_object_t *p_this)
Saves the in-memory configuration into a file.
Definition: file.c:341
strdup
char * strdup(const char *)
module_config_t::min
module_value_t min
Definition: vlc_configuration.h:77
module_get_name
const char * module_get_name(const module_t *m, bool long_name)
Get the human-friendly name of a module.
Definition: modules.c:77
psz_value
char psz_value[8]
Definition: vout_intf.c:91
module_config_t::list
union module_config_t::@147 list
vlc_getopt_s::first_nonopt
int first_nonopt
Definition: vlc_getopt.h:83
LC_NUMERIC_MASK
#define LC_NUMERIC_MASK
Definition: vlc_fixups.h:338
vlc_block.h
list
module_config_t ** list
Definition: core.c:460
name
const char name[16]
Definition: httpd.c:1249
print_desc
static void print_desc(const char *str, unsigned margin, bool color)
Definition: help.c:260
vlc_strtoi
static int64_t vlc_strtoi(const char *str)
Definition: file.c:140
config_GetUserDir
char * config_GetUserDir(vlc_userdir_t type)
Definition: specific.c:272
ListModules
static void ListModules(vlc_object_t *, bool)
Definition: help.c:669
vlc_rwlock_t
pthread_rwlock_t vlc_rwlock_t
Read/write lock.
Definition: vlc_threads.h:304
config_PutInt
void config_PutInt(vlc_object_t *p_this, const char *psz_name, int64_t i_value)
Definition: core.c:218
CONFIG_FILE
#define CONFIG_FILE
Definition: configuration.h:58
module_config_t::b_advanced
unsigned b_advanced
Definition: vlc_configuration.h:64
module_value_t::i
int64_t i
Definition: vlc_configuration.h:51
N_
#define N_(str)
Definition: vlc_fixups.h:372
config
static struct @10 config
module_config_t::value
module_value_t value
Definition: vlc_configuration.h:75
vlc_http_msg_can_seek
static bool vlc_http_msg_can_seek(const struct vlc_http_msg *resp)
Definition: file.c:168
GRAY
#define GRAY
Definition: help.c:240
module_value_t::f
float f
Definition: vlc_configuration.h:52
config_GetIntChoices
ssize_t config_GetIntChoices(vlc_object_t *obj, const char *name, int64_t **restrict values, char ***restrict texts)
Determines a list of suggested values for an integer configuration item.
Definition: core.c:285
configuration.h
config_lock
vlc_rwlock_t config_lock
Definition: core.c:40
config_lock
vlc_rwlock_t config_lock
Definition: core.c:40
vlc_http_msg_get_mtime
time_t vlc_http_msg_get_mtime(const struct vlc_http_msg *m)
Gets resource date.
Definition: message.c:830
strtoll
long long int strtoll(const char *, char **, int)
YELLOW
#define YELLOW
Definition: help.c:235
vlc_mutex_unlock
void vlc_mutex_unlock(vlc_mutex_t *p_mutex)
Releases a mutex.
Definition: thread.c:138
CONFIG_ITEM_MODULE
#define CONFIG_ITEM_MODULE
Definition: vlc_plugin.h:127
unlikely
#define unlikely(p)
Definition: vlc_common.h:114
module_config_t::list_count
uint16_t list_count
Definition: vlc_configuration.h:81
module_config_t::psz_longtext
const char * psz_longtext
Definition: vlc_configuration.h:73
rewind
void rewind(FILE *)
module_config_t::i_type
uint8_t i_type
Definition: vlc_configuration.h:62
module_config_t::psz
const char ** psz
Definition: vlc_configuration.h:84
vlc_getopt_t
struct vlc_getopt_s vlc_getopt_t
libvlc.h
module_match
static bool module_match(const module_t *m, const char *pattern, bool strict)
Definition: help.c:543
vlc_strerror_c
const char * vlc_strerror_c(int errnum)
Definition: error.c:34
vlc_http_res_read
struct block_t * vlc_http_res_read(struct vlc_http_resource *res)
Reads data.
Definition: resource.c:321
vlc_http_file::resource
struct vlc_http_resource resource
Definition: file.c:60
config_PutFloat
void config_PutFloat(vlc_object_t *p_this, const char *psz_name, float f_value)
Definition: core.c:249
vlc_http_msg_get_header
const char * vlc_http_msg_get_header(const struct vlc_http_msg *m, const char *name)
Looks up an header field.
Definition: message.c:154
config_PutPsz
#define config_PutPsz(a, b, c)
Definition: vlc_configuration.h:147
vlc_assert_unreachable
#define vlc_assert_unreachable()
Definition: vlc_common.h:118
file.h
vlc_rwlock_rdlock
void vlc_rwlock_rdlock(vlc_rwlock_t *lock)
Acquires a read/write lock for reading.
Definition: thread.c:381
vlc_http_msg_get_status
int vlc_http_msg_get_status(const struct vlc_http_msg *m)
Gets response status code.
Definition: message.c:166
module_config_t::i_short
char i_short
Definition: vlc_configuration.h:63
config_SortConfig
int config_SortConfig(void)
Index the configuration items by name for faster lookups.
Definition: core.c:467
utf8_fprintf
int utf8_fprintf(FILE *stream, const char *fmt,...)
Formats an UTF-8 string as fprintf(), then print it, with appropriate conversion to local encoding.
Definition: unicode.c:100
CONFIG_HINT_CATEGORY
#define CONFIG_HINT_CATEGORY
Definition: vlc_plugin.h:112
config_PrintHelp
bool config_PrintHelp(vlc_object_t *obj)
Checks for help command line options such as –help or –version.
Definition: help.c:94
config_AutoSaveConfigFile
int config_AutoSaveConfigFile(vlc_object_t *p_this)
Definition: file.c:522
CONFIG_HINT_USAGE
#define CONFIG_HINT_USAGE
Definition: vlc_plugin.h:113
vlc_actions.h
config_LoadConfigFile
int config_LoadConfigFile(vlc_object_t *p_this)
Definition: file.c:167
print_item
static void print_item(const vlc_object_t *p_this, const module_t *m, const module_config_t *item, const module_config_t **section, bool color, bool desc)
Definition: help.c:345
vlc_usage
static const char vlc_usage[]
Definition: help.c:165
vlc_http_msg_add_time
int vlc_http_msg_add_time(struct vlc_http_msg *m, const char *hname, const time_t *t)
Adds a timestamp header field.
Definition: message.c:764
VLC_OBJECT
#define VLC_OBJECT(x)
Type-safe vlc_object_t cast.
Definition: vlc_common.h:464
ShowConsole
#define ShowConsole()
Definition: help.c:53
LICENSE_MSG
#define LICENSE_MSG
Definition: vlc_common.h:1028
vlc_alloc
static void * vlc_alloc(size_t count, size_t size)
Definition: vlc_common.h:948
config_Write
static int config_Write(FILE *file, const char *desc, const char *type, bool comment, const char *name, const char *fmt,...)
Definition: file.c:300
vlc_http_resource_cbs
Definition: resource.h:34
vlc_http_msg_get_size
uintmax_t vlc_http_msg_get_size(const struct vlc_http_msg *m)
Gets HTTP payload length.
Definition: message.c:858
config_Free
void config_Free(module_config_t *tab, size_t confsize)
Destroys an array of configuration items.
Definition: core.c:529
VLC_STATIC_MUTEX
#define VLC_STATIC_MUTEX
Static initializer for (static) mutex.
Definition: vlc_threads.h:272
vlc_getopt_s
Definition: vlc_getopt.h:24
vlc_http_msg
Definition: message.c:40
vlc_http_msg_get_file_size
static uintmax_t vlc_http_msg_get_file_size(const struct vlc_http_msg *resp)
Definition: file.c:131
vlc_option::flag
int * flag
Definition: vlc_getopt.h:94
GREEN
#define GREEN
Definition: help.c:234
vlc_mutex_lock
void vlc_mutex_lock(vlc_mutex_t *p_mutex)
Acquires a mutex.
Definition: thread.c:123
config_OpenConfigFile
static FILE * config_OpenConfigFile(vlc_object_t *p_obj)
Definition: file.c:73
block_t
Definition: vlc_block.h:111
vlc_plugin_t::conf
struct vlc_plugin_t::@70 conf
Variables set by the module to store its config options.
VLC_STATIC_RWLOCK
#define VLC_STATIC_RWLOCK
Static initializer for (static) read/write lock.
Definition: vlc_threads.h:309
vlc_http_file_seek
int vlc_http_file_seek(struct vlc_http_resource *res, uintmax_t offset)
Sets the read offset.
Definition: file.c:203
msg_Err
#define msg_Err(p_this,...)
Definition: vlc_messages.h:82
vlc_object_t::obj
struct vlc_common_members obj
Definition: vlc_objects.h:42
config_ExistIntf
bool config_ExistIntf(vlc_object_t *p_this, const char *psz_intf)
Definition: intf.c:142
CONFIG_ITEM
#define CONFIG_ITEM(x)
Definition: vlc_plugin.h:136
getline
ssize_t getline(char **, size_t *, FILE *)
p
#define p(t)
config_AddIntf
void config_AddIntf(vlc_object_t *p_this, const char *psz_intf)
Definition: intf.c:33
vlc_modules.h
module_config_t::b_safe
unsigned b_safe
Definition: vlc_configuration.h:67