Commit de19a1c7 authored by Clément Stenac's avatar Clément Stenac

Initialize variables

parent a10232da
......@@ -336,7 +336,7 @@ static inline int __var_SetVoid( vlc_object_t *p_obj, const char *psz_name )
*/
static inline int __var_GetInteger( vlc_object_t *p_obj, const char *psz_name )
{
vlc_value_t val;
vlc_value_t val;val.i_int = 0;
if( !__var_Get( p_obj, psz_name, &val ) )
return val.i_int;
else
......@@ -351,7 +351,7 @@ static inline int __var_GetInteger( vlc_object_t *p_obj, const char *psz_name )
*/
static inline int __var_GetBool( vlc_object_t *p_obj, const char *psz_name )
{
vlc_value_t val;
vlc_value_t val; val.b_bool = VLC_FALSE;
if( !__var_Get( p_obj, psz_name, &val ) )
return val.b_bool;
else
......@@ -366,7 +366,7 @@ static inline int __var_GetBool( vlc_object_t *p_obj, const char *psz_name )
*/
static inline int64_t __var_GetTime( vlc_object_t *p_obj, const char *psz_name )
{
vlc_value_t val;
vlc_value_t val; val.i_time = 0L;
if( !__var_Get( p_obj, psz_name, &val ) )
return val.i_time;
else
......@@ -381,7 +381,7 @@ static inline int64_t __var_GetTime( vlc_object_t *p_obj, const char *psz_name )
*/
static inline float __var_GetFloat( vlc_object_t *p_obj, const char *psz_name )
{
vlc_value_t val;
vlc_value_t val; val.f_float = 0.0;
if( !__var_Get( p_obj, psz_name, &val ) )
return val.f_float;
else
......@@ -396,7 +396,7 @@ static inline float __var_GetFloat( vlc_object_t *p_obj, const char *psz_name )
*/
static inline char *__var_GetString( vlc_object_t *p_obj, const char *psz_name )
{
vlc_value_t val;
vlc_value_t val; val.psz_string = NULL;
if( !__var_Get( p_obj, psz_name, &val ) )
return val.psz_string;
else
......
......@@ -290,7 +290,7 @@ VLC_EXPORT( counter_t*, __stats_CounterGet, (vlc_object_t*, int, unsigned int )
static inline int __stats_GetInteger( vlc_object_t *p_obj, int i_id,
unsigned int i_counter, int *value )
{
vlc_value_t val;
vlc_value_t val; val.i_int = 0;
int i_ret = __stats_Get( p_obj, i_id, i_counter, &val );
*value = val.i_int;
return i_ret;
......@@ -300,7 +300,7 @@ static inline int __stats_GetInteger( vlc_object_t *p_obj, int i_id,
static inline int __stats_GetFloat( vlc_object_t *p_obj, int i_id,
unsigned int i_counter, float *value )
{
vlc_value_t val;
vlc_value_t val;val.f_float = 0.0;
int i_ret = __stats_Get( p_obj, i_id, i_counter, &val );
*value = val.f_float;
return i_ret;
......@@ -312,7 +312,7 @@ static inline int __stats_UpdateInteger( vlc_object_t *p_obj,
{
int i_ret;
vlc_value_t val;
vlc_value_t new_val;
vlc_value_t new_val; new_val.i_int = 0;
val.i_int = i;
i_ret = __stats_Update( p_obj, i_counter, val , &new_val );
if( pi_new )
......@@ -326,7 +326,7 @@ static inline int __stats_UpdateFloat( vlc_object_t *p_obj,
{
vlc_value_t val;
int i_ret;
vlc_value_t new_val;
vlc_value_t new_val;new_val.f_float = 0.0;
val.f_float = f;
i_ret = __stats_Update( p_obj, i_counter, val, &new_val );
if( pf_new )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment