summaryrefslogtreecommitdiffstats
path: root/libmpcodecs
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2005-01-20 13:22:53 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2005-01-20 13:22:53 +0000
commit6e450282a69f5437b737872d798c611cbe7064ad (patch)
treec72b2eb58f623ef4ee75c745e8bda5361ddc470b /libmpcodecs
parent6974dfae6b1db5ed81cfc66ae721f8a36d42bfda (diff)
downloadmpv-6e450282a69f5437b737872d798c611cbe7064ad.tar.bz2
mpv-6e450282a69f5437b737872d798c611cbe7064ad.tar.xz
remove all setlocale calls, they break the behaviour of sscanf and
strcasecmp, especially with tr_TR locale - and do not seem to be good for anything. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@14543 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs')
-rw-r--r--libmpcodecs/ad_libvorbis.c10
-rw-r--r--libmpcodecs/vf_eq2.c10
-rw-r--r--libmpcodecs/vf_smartblur.c10
-rw-r--r--libmpcodecs/vf_unsharp.c10
4 files changed, 0 insertions, 40 deletions
diff --git a/libmpcodecs/ad_libvorbis.c b/libmpcodecs/ad_libvorbis.c
index 9bee3678da..e8c25a1887 100644
--- a/libmpcodecs/ad_libvorbis.c
+++ b/libmpcodecs/ad_libvorbis.c
@@ -8,10 +8,6 @@
#include "config.h"
#include "ad_internal.h"
-#ifdef USE_SETLOCALE
-#include <locale.h>
-#endif
-
#ifdef HAVE_OGGVORBIS
static ad_info_t info =
@@ -50,13 +46,7 @@ static int read_vorbis_comment( char* ptr, char* comment, char* format, ... ) {
va_start( va, format );
clen = strlen( comment );
-#ifdef USE_SETLOCALE
- setlocale( LC_NUMERIC, "C" );
-#endif
ret = strncasecmp( ptr, comment, clen) == 0 ? vsscanf( ptr+clen, format, va ) : 0;
-#ifdef USE_SETLOCALE
- setlocale( LC_NUMERIC, "" );
-#endif
va_end( va );
return ret;
diff --git a/libmpcodecs/vf_eq2.c b/libmpcodecs/vf_eq2.c
index f2641f9c0b..f9aea4f223 100644
--- a/libmpcodecs/vf_eq2.c
+++ b/libmpcodecs/vf_eq2.c
@@ -23,10 +23,6 @@
#include "mp_image.h"
#include "vf.h"
-#ifdef USE_SETLOCALE
-#include <locale.h>
-#endif
-
#define LUT16
/* Per channel parameters */
@@ -481,15 +477,9 @@ int open (vf_instance_t *vf, char *args)
par[5] = 1.0;
par[6] = 1.0;
par[7] = 1.0;
-#ifdef USE_SETLOCALE
- setlocale (LC_NUMERIC, "C");
-#endif
sscanf (args, "%lf:%lf:%lf:%lf:%lf:%lf:%lf:%lf",
par, par + 1, par + 2, par + 3, par + 4, par + 5, par + 6, par + 7
);
-#ifdef USE_SETLOCALE
- setlocale (LC_NUMERIC, "");
-#endif
eq2->rgamma = par[4];
eq2->ggamma = par[5];
diff --git a/libmpcodecs/vf_smartblur.c b/libmpcodecs/vf_smartblur.c
index bdc4064ed2..a83a11e46b 100644
--- a/libmpcodecs/vf_smartblur.c
+++ b/libmpcodecs/vf_smartblur.c
@@ -25,10 +25,6 @@
#include "../config.h"
#include "../mp_msg.h"
-#ifdef USE_SETLOCALE
-#include <locale.h>
-#endif
-
#ifdef HAVE_MALLOC_H
#include <malloc.h>
#endif
@@ -235,9 +231,6 @@ static int open(vf_instance_t *vf, char* args){
if(args==NULL) return 0;
-#ifdef USE_SETLOCALE
- setlocale( LC_NUMERIC, "C" );
-#endif
e=sscanf(args, "%f:%f:%d:%f:%f:%d",
&vf->priv->luma.radius,
&vf->priv->luma.strength,
@@ -246,9 +239,6 @@ static int open(vf_instance_t *vf, char* args){
&vf->priv->chroma.strength,
&vf->priv->chroma.threshold
);
-#ifdef USE_SETLOCALE
- setlocale( LC_NUMERIC, "" );
-#endif
vf->priv->luma.quality = vf->priv->chroma.quality= 3.0;
diff --git a/libmpcodecs/vf_unsharp.c b/libmpcodecs/vf_unsharp.c
index 40b993139a..4989e2e658 100644
--- a/libmpcodecs/vf_unsharp.c
+++ b/libmpcodecs/vf_unsharp.c
@@ -27,10 +27,6 @@
#include "../mp_msg.h"
#include "../cpudetect.h"
-#ifdef USE_SETLOCALE
-#include <locale.h>
-#endif
-
#ifdef HAVE_MALLOC_H
#include <malloc.h>
#endif
@@ -267,13 +263,7 @@ static void parse( FilterParam *fp, char* args ) {
// parse amount
pos = strchr( pos+1, ':' );
-#ifdef USE_SETLOCALE
- setlocale( LC_NUMERIC, "C" );
-#endif
fp->amount = ( pos && pos+1<max ) ? atof( pos+1 ) : 0;
-#ifdef USE_SETLOCALE
- setlocale( LC_NUMERIC, "" );
-#endif
}
//===========================================================================//