changeset 6324:e378dca8784f libavcodec

const
author michael
date Sun, 03 Feb 2008 23:25:35 +0000
parents e6da66f378c7
children 6335f2688c04
files eval.c eval.h
diffstat 2 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/eval.c	Sun Feb 03 17:54:30 2008 +0000
+++ b/eval.c	Sun Feb 03 23:25:35 2008 +0000
@@ -55,7 +55,7 @@
     double (**func2)(void *, double a, double b); // NULL terminated
     char **func2_name;          // NULL terminated
     void *opaque;
-    char **error;
+    const char **error;
 #define VARS 10
     double var[VARS];
 } Parser;
@@ -379,7 +379,7 @@
 AVEvalExpr * ff_parse(char *s, const char **const_name,
                double (**func1)(void *, double), const char **func1_name,
                double (**func2)(void *, double, double), char **func2_name,
-               char **error){
+               const char **error){
     Parser p;
     AVEvalExpr * e;
     char w[strlen(s) + 1], * wp = w;
@@ -416,7 +416,7 @@
 double ff_eval2(char *s, double *const_value, const char **const_name,
                double (**func1)(void *, double), const char **func1_name,
                double (**func2)(void *, double, double), char **func2_name,
-               void *opaque, char **error){
+               void *opaque, const char **error){
     AVEvalExpr * e = ff_parse(s, const_name, func1, func1_name, func2, func2_name, error);
     double d;
     if (!e) return NAN;
@@ -430,7 +430,7 @@
                double (**func1)(void *, double), const char **func1_name,
                double (**func2)(void *, double, double), char **func2_name,
                void *opaque){
-    char *error=NULL;
+    const char *error=NULL;
     double ret;
     ret = ff_eval2(s, const_value, const_name, func1, func1_name, func2, func2_name, opaque, &error);
     if (error)
--- a/eval.h	Sun Feb 03 17:54:30 2008 +0000
+++ b/eval.h	Sun Feb 03 23:25:35 2008 +0000
@@ -55,7 +55,7 @@
 double ff_eval2(char *s, double *const_value, const char **const_name,
                double (**func1)(void *, double), const char **func1_name,
                double (**func2)(void *, double, double), char **func2_name,
-               void *opaque, char **error);
+               void *opaque, const char **error);
 
 typedef struct ff_expr_s AVEvalExpr;
 
@@ -74,7 +74,7 @@
 AVEvalExpr * ff_parse(char *s, const char **const_name,
                double (**func1)(void *, double), const char **func1_name,
                double (**func2)(void *, double, double), char **func2_name,
-               char **error);
+               const char **error);
 /**
  * Evaluates a previously parsed expression.
  * @param const_value a zero terminated array of values for the identifers from ff_parse const_name