Commit 0dc7e954 authored by Ralph Giles's avatar Ralph Giles

Merge branch 'master' into mingw

parents 0f237c4a 96c04cdd
......@@ -19,7 +19,7 @@ AC_CONFIG_MACRO_DIR([m4])
AC_USE_SYSTEM_EXTENSIONS
AC_SYS_LARGEFILE
AM_INIT_AUTOMAKE([1.11 foreign no-define dist-zip])
AM_INIT_AUTOMAKE([1.11 foreign no-define dist-zip subdir-objects])
AM_MAINTAINER_MODE([enable])
LT_INIT
......@@ -33,9 +33,9 @@ dnl - interfaces added/removed/changed -> increment CURRENT, REVISION = 0
dnl - interfaces added -> increment AGE
dnl - interfaces removed -> AGE = 0
OP_LT_CURRENT=2
OP_LT_CURRENT=3
OP_LT_REVISION=0
OP_LT_AGE=2
OP_LT_AGE=3
AC_SUBST(OP_LT_CURRENT)
AC_SUBST(OP_LT_REVISION)
......
......@@ -165,6 +165,7 @@ int main(int _argc,const char **_argv){
}
#else
if(of==NULL)of=op_open_file(_argv[1],&ret);
#endif
else{
if(info.name!=NULL){
fprintf(stderr,"Station name: %s\n",info.name);
......@@ -195,7 +196,6 @@ int main(int _argc,const char **_argv){
is_ssl=info.is_ssl;
opus_server_info_clear(&info);
}
#endif
}
if(of==NULL){
fprintf(stderr,"Failed to open file '%s': %i\n",_argv[1],ret);
......
......@@ -141,7 +141,7 @@ static wchar_t *op_utf8_to_utf16(const char *_src){
size_t len;
len=strlen(_src);
/*Worst-case output is 1 wide character per 1 input character.*/
dst=(wchar_t *)malloc(sizeof(*dst)*(len+1));
dst=(wchar_t *)_ogg_malloc(sizeof(*dst)*(len+1));
if(dst!=NULL){
size_t si;
size_t di;
......@@ -218,7 +218,7 @@ static wchar_t *op_utf8_to_utf16(const char *_src){
}
}
/*If we got here, we encountered an illegal UTF-8 sequence.*/
free(dst);
_ogg_free(dst);
return NULL;
}
OP_ASSERT(di<=len);
......@@ -244,8 +244,8 @@ void *op_fopen(OpusFileCallbacks *_cb,const char *_path,const char *_mode){
if(wmode==NULL)errno=EINVAL;
else if(wpath==NULL)errno=ENOENT;
else fp=_wfopen(wpath,wmode);
free(wmode);
free(wpath);
_ogg_free(wmode);
_ogg_free(wpath);
}
#endif
if(fp!=NULL)*_cb=*&OP_FILE_CALLBACKS;
......@@ -275,8 +275,8 @@ void *op_freopen(OpusFileCallbacks *_cb,const char *_path,const char *_mode,
if(wmode==NULL)errno=EINVAL;
else if(wpath==NULL)errno=ENOENT;
else fp=_wfreopen(wpath,wmode,(FILE *)_stream);
free(wmode);
free(wpath);
_ogg_free(wmode);
_ogg_free(wpath);
}
#endif
if(fp!=NULL)*_cb=*&OP_FILE_CALLBACKS;
......
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