diff options
-rw-r--r-- | include/xine.h.in | 118 | ||||
-rw-r--r-- | src/xine-engine/configfile.c | 55 | ||||
-rw-r--r-- | src/xine-engine/configfile.h | 48 | ||||
-rw-r--r-- | src/xine-engine/load_plugins.c | 15 | ||||
-rw-r--r-- | src/xine-engine/xine.c | 76 | ||||
-rw-r--r-- | src/xine-engine/xine_interface.c | 36 | ||||
-rw-r--r-- | src/xine-engine/xine_internal.h | 8 |
7 files changed, 185 insertions, 171 deletions
diff --git a/include/xine.h.in b/include/xine.h.in index fbd4f9744..48feb1b17 100644 --- a/include/xine.h.in +++ b/include/xine.h.in @@ -17,13 +17,22 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine.h.in,v 1.11 2002/09/09 19:24:48 f1rmb Exp $ + * $Id: xine.h.in,v 1.12 2002/09/11 17:41:07 guenter Exp $ * * public xine-lib (libxine) interface and documentation * - * _important_note_: as a rule of thumb, never free() any pointers - * returned by the xine engine - * (unless stated otherwise) + * + * some programming guidelines about this api: + * ------------------------------------------- + * + * (1) libxine has (per instance) a fairly static memory + * model + * (2) as a rule of thumb, never free() or realloc() any pointers + * returned by the xine engine (unless stated otherwise) + * (3) xine is multi-threaded, make sure your programming environment + * can handle this. + * for x11-related stuff this means that you either have to properly + * use xlockdisplay() or use two seperate connections to the x-server * */ @@ -63,6 +72,10 @@ typedef const xine_vo_driver_t *const xine_vo_driver_p; * utility function - see below) and then call xine_open_audio * and xine_open_video to obtain audio/video pointers which * you then pass to the xine_init function. + * + * the only proper way to shut down the xine engine is to + * call xine_exit() - do not try to free() the xine pointer + * yourself and do not try to access any internal data structures */ xine_p xine_new (void); @@ -80,10 +93,10 @@ xine_p xine_new (void); * found ... */ -xine_ao_driver_p xine_open_audio_driver (xine_p self, char *id, +xine_ao_driver_p xine_open_audio_driver (xine_p self, const char *id, void *data); -xine_vo_driver_p xine_open_video_driver (xine_p self, char *id, +xine_vo_driver_p xine_open_video_driver (xine_p self, const char *id, int visual, void *data); /* @@ -100,7 +113,7 @@ void xine_init (xine_p self, xine_ao_driver_p ao, xine_vo_driver_p vo); * * returns 1 if OK, 0 on error (use xine_get_error for details) */ -int xine_open (xine_p self, char *mrl); +int xine_open (xine_p self, const char *mrl); /* * play a stream from a given position @@ -167,10 +180,16 @@ int xine_get_param (xine_p self, int param); /* * try to find out audio/spu language of given channel * (use -1 for current channel) - * returns 1 if ok, 0 on failure + * + * returns 0-terminated string on success, NULL otherwise + * + * the pointer returned by xine_get_audio_lang stays valid until + * xine_get_audio_lang is called again. + * the pointer returned by xine_get_spu_lang stays valid until + * xine_get_spu_lang is called again. */ -int xine_get_audio_lang (xine_p self, int channel, char *str); -int xine_get_spu_lang (xine_p self, int channel, char *str); +const char *xine_get_audio_lang (xine_p self, int channel); +const char *xine_get_spu_lang (xine_p self, int channel); /* * get position / length information @@ -245,7 +264,8 @@ void xine_register_log_cb (xine_p self, xine_log_cb_t cb, #define XINE_CODEC_VIDEO 1 typedef void (*xine_report_codec_cb_t) (void *user_data, int codec_type, - uint32_t fourcc, const char *description, + uint32_t fourcc, + const char *description, int handled); /* * register an codec reporting callback @@ -430,17 +450,22 @@ const char *const *xine_get_browsable_input_plugin_ids (xine_p self) ; * returns <start_mrl> if <start_mrl> is a valid MRL, not a directory * returns NULL if <start_mrl> is an invalid MRL, not even a directory. */ -const xine_mrl_t *const *xine_get_browse_mrls (xine_p self, char *plugin_id, - char *start_mrl, int *num_mrls); +const xine_mrl_t *const *xine_get_browse_mrls (xine_p self, + const char *plugin_id, + const char *start_mrl, + int *num_mrls); /* get a list of plugins that support the autoplay feature */ const char *const *xine_get_autoplay_input_plugin_ids (xine_p self); /* get autoplay MRL list from input plugin named <plugin_id> */ -const char *const *xine_get_autoplay_mrls (xine_p self, char *plugin_id, int *num_mrls); +const char *const *xine_get_autoplay_mrls (xine_p self, + const char *plugin_id, + int *num_mrls); /* get a description string for an input plugin */ -const char *xine_get_input_plugin_description (xine_p self, char *plugin_id); +const char *xine_get_input_plugin_description (xine_p self, + const char *plugin_id); /* get lists of available audio and video output plugins */ const char *const *xine_list_audio_output_plugins (xine_p self) ; @@ -579,7 +604,7 @@ typedef struct xine_cfg_entry_s xine_cfg_entry_t; typedef void (*xine_config_cb_t) (void *user_data, xine_cfg_entry_t *entry); struct xine_cfg_entry_s { - char *key; /* unique id (example: gui.logo_mrl) */ + const char *key; /* unique id (example: gui.logo_mrl) */ int type; @@ -603,8 +628,8 @@ struct xine_cfg_entry_s { char **enum_values; /* help info for the user */ - char *description; - char *help; + const char *description; + const char *help; /* user experience level */ int exp_level; /* 0 => beginner, @@ -617,50 +642,49 @@ struct xine_cfg_entry_s { }; -const char *xine_config_register_string ( - xine_p self, - char *key, - char *def_value, - char *description, - char *help, - int exp_level, - xine_config_cb_t changed_cb, - void *cb_data); +const char *xine_config_register_string (xine_p self, + const char *key, + const char *def_value, + const char *description, + const char *help, + int exp_level, + xine_config_cb_t changed_cb, + void *cb_data); int xine_config_register_range (xine_p self, - char *key, + const char *key, int def_value, int min, int max, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); int xine_config_register_enum (xine_p self, - char *key, + const char *key, int def_value, char **values, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); int xine_config_register_num (xine_p self, - char *key, + const char *key, int def_value, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); int xine_config_register_bool (xine_p self, - char *key, + const char *key, int def_value, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); @@ -673,17 +697,24 @@ xine_cfg_entry_t *xine_config_get_first_entry (xine_p self); /* * get next config item (iterate through the items) * this will return NULL when called after returning the last item + * + * do not free() or realloc() the pointer returned by this function. */ xine_cfg_entry_t *xine_config_get_next_entry (xine_p self); /* * search for a config entry by key + * + * do not free() or realloc() the pointer returned by this function. */ -xine_cfg_entry_t *xine_config_lookup_entry (xine_p self, char *key); +xine_cfg_entry_t *xine_config_lookup_entry (xine_p self, const char *key); /* * update a config entry (which was returned from lookup_entry() ) + * + * xine will make a deep copy of the data in the entry into it's internal + * config database. */ void xine_config_update_entry (xine_p self, xine_cfg_entry_t *entry); @@ -692,9 +723,9 @@ void xine_config_update_entry (xine_p self, * load/save config data from/to afile (e.g. $HOME/.xine/config) */ void xine_load_config (xine_p self, - char *cfg_filename); + const char *cfg_filename); void xine_save_config (xine_p self, - char *cfg_filename); + const char *cfg_filename); void xine_reset_config (xine_p self); /* @@ -923,7 +954,8 @@ void xine_osd_clear (xine_osd_p self); * osd objects are closed */ void xine_osd_free (xine_osd_p self); -void xine_osd_set_palette (xine_osd_p self, const uint32_t *const color, +void xine_osd_set_palette (xine_osd_p self, + const uint32_t *const color, const uint8_t *const trans ); /* * set on existing text palette diff --git a/src/xine-engine/configfile.c b/src/xine-engine/configfile.c index 907860ca9..9d34b108b 100644 --- a/src/xine-engine/configfile.c +++ b/src/xine-engine/configfile.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: configfile.c,v 1.29 2002/09/10 14:06:33 jcdutton Exp $ + * $Id: configfile.c,v 1.30 2002/09/11 17:41:08 guenter Exp $ * * config object (was: file) management - implementation * @@ -46,7 +46,7 @@ * internal utility functions */ -static char *copy_string (char *str) { +static char *copy_string (const char *str) { char *cpy; int len; @@ -60,7 +60,7 @@ static char *copy_string (char *str) { return cpy; } -static cfg_entry_t *xine_config_add (config_values_t *this, char *key) { +static cfg_entry_t *xine_config_add (config_values_t *this, const char *key) { cfg_entry_t *entry; @@ -92,7 +92,7 @@ static cfg_entry_t *xine_config_add (config_values_t *this, char *key) { * external interface */ -static cfg_entry_t *_xine_config_lookup_entry (config_values_t *this, char *key) { +static cfg_entry_t *_xine_config_lookup_entry (config_values_t *this, const char *key) { cfg_entry_t *entry; entry = this->first; @@ -105,9 +105,10 @@ static cfg_entry_t *_xine_config_lookup_entry (config_values_t *this, char *key) static char *_xine_config_register_string (config_values_t *this, - char *key, char *def_value, - char *description, - char *help, + const char *key, + const char *def_value, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -168,9 +169,9 @@ static char *_xine_config_register_string (config_values_t *this, } static int _xine_config_register_num (config_values_t *this, - char *key, int def_value, - char *description, - char *help, + const char *key, int def_value, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -223,9 +224,10 @@ static int _xine_config_register_num (config_values_t *this, } static int _xine_config_register_bool (config_values_t *this, - char *key, int def_value, - char *description, - char *help, + const char *key, + int def_value, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -278,10 +280,11 @@ static int _xine_config_register_bool (config_values_t *this, } static int _xine_config_register_range (config_values_t *this, - char *key, int def_value, + const char *key, + int def_value, int min, int max, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -333,7 +336,7 @@ static int _xine_config_register_range (config_values_t *this, return entry->num_value; } -static int xine_config_parse_enum (char *str, char **values) { +static int xine_config_parse_enum (const char *str, char **values) { char **value; int i; @@ -365,10 +368,11 @@ static int xine_config_parse_enum (char *str, char **values) { } static int _xine_config_register_enum (config_values_t *this, - char *key, int def_value, + const char *key, + int def_value, char **values, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -442,7 +446,7 @@ static void xine_config_shallow_copy(xine_cfg_entry_t *dest, cfg_entry_t *src) } static void xine_config_update_num (config_values_t *this, - char *key, int value) { + const char *key, int value) { cfg_entry_t *entry; @@ -480,7 +484,8 @@ static void xine_config_update_num (config_values_t *this, } static void xine_config_update_string (config_values_t *this, - char *key, char *value) { + const char *key, + const char *value) { cfg_entry_t *entry; @@ -521,7 +526,7 @@ static void xine_config_update_string (config_values_t *this, /* * load/save config data from/to afile (e.g. $HOME/.xine/config) */ -void xine_load_config (xine_p xine_ro, char *filename) { +void xine_load_config (xine_p xine_ro, const char *filename) { config_values_t *this = xine_ro->config; FILE *f_config; @@ -580,7 +585,7 @@ void xine_load_config (xine_p xine_ro, char *filename) { } } -void xine_save_config (xine_p xine_ro, char *filename) { +void xine_save_config (xine_p xine_ro, const char *filename) { config_values_t *this = xine_ro->config; FILE *f_config; @@ -696,7 +701,7 @@ static void xine_config_dispose (config_values_t *this) { static void xine_config_unregister_cb (config_values_t *this, - char *key) { + const char *key) { cfg_entry_t *entry; diff --git a/src/xine-engine/configfile.h b/src/xine-engine/configfile.h index e2c17f1b6..d19c70648 100644 --- a/src/xine-engine/configfile.h +++ b/src/xine-engine/configfile.h @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: configfile.h,v 1.14 2002/09/09 19:24:48 f1rmb Exp $ + * $Id: configfile.h,v 1.15 2002/09/11 17:41:08 guenter Exp $ * * config file management * @@ -65,8 +65,8 @@ struct cfg_entry_s { char **enum_values; /* help info for the user */ - char *description; - char *help; + const char *description; + const char *help; /* user experience level */ int exp_level; @@ -99,60 +99,60 @@ struct config_values_s { */ char* (*register_string) (config_values_t *this, - char *key, - char *def_value, - char *description, - char *help, + const char *key, + const char *def_value, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); int (*register_range) (config_values_t *this, - char *key, + const char *key, int def_value, int min, int max, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); int (*register_enum) (config_values_t *this, - char *key, + const char *key, int def_value, char **values, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); int (*register_num) (config_values_t *this, - char *key, + const char *key, int def_value, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); int (*register_bool) (config_values_t *this, - char *key, + const char *key, int def_value, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data); /* convenience function to update range, enum, num and bool values */ - void (*update_num) (config_values_t *this, char *key, int value); + void (*update_num) (config_values_t *this, const char *key, int value); /* convenience function to update string values */ - void (*update_string) (config_values_t *this, char *key, char *value); + void (*update_string) (config_values_t *this, const char *key, const char *value); /* small utility function for enum handling */ - int (*parse_enum) (char *str, char **values); + int (*parse_enum) (const char *str, char **values); /* * lookup config entries @@ -161,12 +161,12 @@ struct config_values_s { * and you changed the value of this item */ - cfg_entry_t* (*lookup_entry) (config_values_t *this, char *key); + cfg_entry_t* (*lookup_entry) (config_values_t *this, const char *key); /* * unregister callback function */ - void (*unregister_callback) (config_values_t *this, char *key); + void (*unregister_callback) (config_values_t *this, const char *key); /* * config values are stored here: diff --git a/src/xine-engine/load_plugins.c b/src/xine-engine/load_plugins.c index 5bada58fb..993328f37 100644 --- a/src/xine-engine/load_plugins.c +++ b/src/xine-engine/load_plugins.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: load_plugins.c,v 1.90 2002/09/09 20:41:51 uid86226 Exp $ + * $Id: load_plugins.c,v 1.91 2002/09/11 17:41:08 guenter Exp $ * * * Load input/demux/audio_out/video_out/codec plugins @@ -597,7 +597,7 @@ const char *const *xine_get_browsable_input_plugin_ids(xine_p this) { return (_xine_get_featured_input_plugin_ids(this, INPUT_CAP_GET_DIR)); } -const char *xine_get_input_plugin_description(xine_p this, char *plugin_id) { +const char *xine_get_input_plugin_description(xine_p this, const char *plugin_id) { plugin_catalog_t *catalog; plugin_node_t *node; @@ -623,7 +623,7 @@ const char *xine_get_input_plugin_description(xine_p this, char *plugin_id) { */ xine_vo_driver_p xine_open_video_driver (xine_p this_ro, - char *id, + const char *id, int visual_type, void *visual) { xine_t *this = (xine_t *)this_ro; @@ -716,7 +716,7 @@ const char *const *xine_list_video_output_plugins (xine_p this) { return catalog->ids; } -xine_ao_driver_p xine_open_audio_driver (xine_p this_ro, char *id, +xine_ao_driver_p xine_open_audio_driver (xine_p this_ro, const char *id, void *data) { xine_t *this = (xine_t *)this_ro; @@ -758,7 +758,8 @@ xine_ao_driver_p xine_open_audio_driver (xine_p this_ro, char *id, * get autoplay mrl list from input plugin */ -const char *const *xine_get_autoplay_mrls (xine_p this, char *plugin_id, int *num_mrls) { +const char *const *xine_get_autoplay_mrls (xine_p this, const char *plugin_id, + int *num_mrls) { plugin_catalog_t *catalog; plugin_node_t *node; @@ -787,8 +788,8 @@ const char *const *xine_get_autoplay_mrls (xine_p this, char *plugin_id, int *nu /* * input plugin mrl browser support */ -const xine_mrl_t *const *xine_get_browse_mrls (xine_p this, char *plugin_id, - char *start_mrl, int *num_mrls) { +const xine_mrl_t *const *xine_get_browse_mrls (xine_p this, const char *plugin_id, + const char *start_mrl, int *num_mrls) { plugin_catalog_t *catalog; plugin_node_t *node; diff --git a/src/xine-engine/xine.c b/src/xine-engine/xine.c index 5ef16ffcc..ea58bfc7a 100644 --- a/src/xine-engine/xine.c +++ b/src/xine-engine/xine.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine.c,v 1.155 2002/09/10 14:07:21 mroi Exp $ + * $Id: xine.c,v 1.156 2002/09/11 17:41:08 guenter Exp $ * * top-level xine functions * @@ -363,7 +363,7 @@ static int find_demuxer(xine_t *this) { return 0; } -int xine_open_internal (xine_t *this, char *mrl) { +int xine_open_internal (xine_t *this, const char *mrl) { printf ("xine_open: mrl '%s'\n", mrl); @@ -467,7 +467,7 @@ int xine_open_internal (xine_t *this, char *mrl) { this->cur_demuxer_plugin->get_identifier()); } -#warning ?? limited length ??? + /* FIXME: ?? limited length ??? */ strncpy (this->cur_mrl, mrl, 1024); printf ("xine: xine_open done.\n"); @@ -528,7 +528,7 @@ int xine_play_internal (xine_t *this, int start_pos, int start_time) { return 1; } -int xine_open (xine_p this_ro, char *mrl) { +int xine_open (xine_p this_ro, const char *mrl) { xine_t *this = (xine_t *)this_ro; int ret; @@ -992,60 +992,34 @@ int xine_get_current_frame (xine_p this_ro, int *width, int *height, return 1; } -int xine_get_spu_lang (xine_p this_ro, int channel, char *str) { +const char * xine_get_spu_lang (xine_p this_ro, int channel) { xine_t *this = (xine_t *)this_ro; - switch (this->spu_channel_user) { - case -2: - sprintf (str, "off"); - break; - case -1: - if (this->cur_input_plugin) { - if (this->cur_input_plugin->get_capabilities (this->cur_input_plugin) & INPUT_CAP_SPULANG) { - this->cur_input_plugin->get_optional_data (this->cur_input_plugin, this->str, - INPUT_OPTIONAL_DATA_SPULANG); - sprintf (str, "*(%s)", this->str); - return 1; - } - } - if (this->spu_channel_auto == -1) - sprintf (str, "*(off)"); - else - sprintf (str, "*(%3d)", this->spu_channel_auto); - break; - default: - sprintf (str, "%3d", this->spu_channel_user); - } - return 0; + if (this->cur_input_plugin) { + if (this->cur_input_plugin->get_capabilities (this->cur_input_plugin) & INPUT_CAP_SPULANG) { + this->cur_input_plugin->get_optional_data (this->cur_input_plugin, + this->spu_lang, + INPUT_OPTIONAL_DATA_SPULANG); + return this->spu_lang; + } + } + + return NULL; } -int xine_get_audio_lang (xine_p this_ro, int channel, char *str) { +const char* xine_get_audio_lang (xine_p this_ro, int channel) { xine_t *this = (xine_t *)this_ro; - switch (this->audio_channel_user) { - case -2: - sprintf (str, "off"); - break; - case -1: - if (this->cur_input_plugin) { - if (this->cur_input_plugin->get_capabilities (this->cur_input_plugin) & INPUT_CAP_AUDIOLANG) { - this->cur_input_plugin->get_optional_data (this->cur_input_plugin, this->str, - INPUT_OPTIONAL_DATA_AUDIOLANG); - - sprintf (str, "*(%s)", this->str); + if (this->cur_input_plugin) { + if (this->cur_input_plugin->get_capabilities (this->cur_input_plugin) & INPUT_CAP_AUDIOLANG) { + this->cur_input_plugin->get_optional_data (this->cur_input_plugin, + this->audio_lang, + INPUT_OPTIONAL_DATA_AUDIOLANG); + return this->audio_lang; + } + } - return 1; - } - } - if (this->audio_channel_auto == -1) - sprintf (str, "*(off)"); - else - sprintf (str, "*(%3d)", this->audio_channel_auto); - break; - default: - sprintf (str, "%3d", this->audio_channel_user); - } - return 0; + return NULL; } int xine_get_spu_channel (xine_t *this) { diff --git a/src/xine-engine/xine_interface.c b/src/xine-engine/xine_interface.c index ae52dc031..66e141dbe 100644 --- a/src/xine-engine/xine_interface.c +++ b/src/xine-engine/xine_interface.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_interface.c,v 1.9 2002/09/10 10:40:22 mroi Exp $ + * $Id: xine_interface.c,v 1.10 2002/09/11 17:41:08 guenter Exp $ * * convenience/abstraction layer, functions to implement * libxine's public interface @@ -75,10 +75,10 @@ int xine_check_version(int major, int minor, int sub) { */ const char* xine_config_register_string (xine_p self, - char *key, - char *def_value, - char *description, - char *help, + const char *key, + const char *def_value, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -95,11 +95,11 @@ const char* xine_config_register_string (xine_p self, } int xine_config_register_range (xine_p self, - char *key, + const char *key, int def_value, int min, int max, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -111,11 +111,11 @@ int xine_config_register_range (xine_p self, int xine_config_register_enum (xine_p self, - char *key, + const char *key, int def_value, char **values, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -127,10 +127,10 @@ int xine_config_register_enum (xine_p self, int xine_config_register_num (xine_p self, - char *key, + const char *key, int def_value, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -142,10 +142,10 @@ int xine_config_register_num (xine_p self, int xine_config_register_bool (xine_p self, - char *key, + const char *key, int def_value, - char *description, - char *help, + const char *description, + const char *help, int exp_level, xine_config_cb_t changed_cb, void *cb_data) { @@ -223,7 +223,7 @@ xine_cfg_entry_t *xine_config_get_next_entry (xine_p this) { * search for a config entry by key */ -xine_cfg_entry_t *xine_config_lookup_entry (xine_p this, char *key) { +xine_cfg_entry_t *xine_config_lookup_entry (xine_p this, const char *key) { config_values_t *config = this->config; diff --git a/src/xine-engine/xine_internal.h b/src/xine-engine/xine_internal.h index 4dce3aa88..189a04191 100644 --- a/src/xine-engine/xine_internal.h +++ b/src/xine-engine/xine_internal.h @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_internal.h,v 1.97 2002/09/09 19:24:48 f1rmb Exp $ + * $Id: xine_internal.h,v 1.98 2002/09/11 17:41:08 guenter Exp $ * */ @@ -221,8 +221,10 @@ struct xine_s { void *event_listener_user_data[XINE_MAX_EVENT_LISTENERS]; uint16_t num_event_listeners; - /* scratch string buffer */ + /* scratch string buffers */ char str[1024]; + char spu_lang[80]; + char audio_lang[80]; /* log output that may be presented to the user */ scratch_buffer_t *log_buffers[XINE_LOG_NUM]; @@ -244,7 +246,7 @@ struct xine_s { * private function prototypes: */ -int xine_open_internal (xine_t *this, char *mrl); +int xine_open_internal (xine_t *this, const char *mrl); int xine_play_internal (xine_t *this, int start_pos, int start_time); void xine_stop_internal (xine_t *this); |