1
mirror of https://github.com/mpv-player/mpv synced 2024-11-14 22:48:35 +01:00

vo_opengl: use misc/ctype.h instead of <ctype.h>

Locale-independent, and doesn't have the char vs. unsigned char problem.
(Although in this case, the code was fine, because bstr.start is
unsigned char.)
This commit is contained in:
wm4 2017-02-25 14:33:27 +01:00
parent eacf4a7d9b
commit 2b6ac866c0

View File

@ -15,9 +15,9 @@
* License along with mpv. If not, see <http://www.gnu.org/licenses/>.
*/
#include <ctype.h>
#include <assert.h>
#include "misc/ctype.h"
#include "user_shaders.h"
static bool parse_rpn_szexpr(struct bstr line, struct szexp out[MAX_SZEXP_SIZE])
@ -56,7 +56,7 @@ static bool parse_rpn_szexpr(struct bstr line, struct szexp out[MAX_SZEXP_SIZE])
case '<': exp->tag = SZEXP_OP2; exp->val.op = SZEXP_OP_LT; continue;
}
if (isdigit(word.start[0])) {
if (mp_isdigit(word.start[0])) {
exp->tag = SZEXP_CONST;
if (bstr_sscanf(word, "%f", &exp->val.cval) != 1)
return false;