diff options
| author | hallgren <hallgren@chalmers.se> | 2011-07-29 15:44:19 +0000 |
|---|---|---|
| committer | hallgren <hallgren@chalmers.se> | 2011-07-29 15:44:19 +0000 |
| commit | b58fc79908efb52320a38fdf6df96d8d0d067e73 (patch) | |
| tree | 606e81246df1d5befe3f80905100bd7ef155dbfe /src/editor/simple/upload.cgi | |
| parent | 7c6f6110ebf8ebf446b8414e035b1118908d5bed (diff) | |
gfse: some correctness checks for concrete syntax
The editor now calls the GF server to check the syntax of expressions that
are part of concrete syntax (except for parameter types).
This is currently done by using the cc command of the GF shell, which puts
some unnecessary restricitons on operation definitions...
Diffstat (limited to 'src/editor/simple/upload.cgi')
| -rw-r--r-- | src/editor/simple/upload.cgi | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/editor/simple/upload.cgi b/src/editor/simple/upload.cgi index 3da386dd6..662a1d35d 100644 --- a/src/editor/simple/upload.cgi +++ b/src/editor/simple/upload.cgi @@ -219,6 +219,13 @@ case "$REQUEST_METHOD" in *) error400 esac ;; + cc=*) + # Just to check an expression for syntax errors + exp=$(qparse "$QUERY_STRING" cc) + ContentType="text/plain; charset=$charset" + cgiheaders + echo "cc $exp" | GF_RESTRICTED=True gf -run + ;; *) error400 esac esac |
