equal
deleted
inserted
replaced
9 sig |
9 sig |
10 val set_secure: unit -> unit |
10 val set_secure: unit -> unit |
11 val is_secure: unit -> bool |
11 val is_secure: unit -> bool |
12 val use_text: string -> (string -> unit) * (string -> 'a) -> bool -> string -> unit |
12 val use_text: string -> (string -> unit) * (string -> 'a) -> bool -> string -> unit |
13 val use_file: (string -> unit) * (string -> 'a) -> bool -> string -> unit |
13 val use_file: (string -> unit) * (string -> 'a) -> bool -> string -> unit |
|
14 val use_noncritical: string -> unit |
14 val use: string -> unit |
15 val use: string -> unit |
15 val commit: unit -> unit |
16 val commit: unit -> unit |
16 val execute: string -> string |
17 val execute: string -> string |
17 val system: string -> int |
18 val system: string -> int |
18 end; |
19 end; |
43 (secure_mltext (); orig_use_text name pr verbose txt)); |
44 (secure_mltext (); orig_use_text name pr verbose txt)); |
44 |
45 |
45 fun use_file pr verbose name = CRITICAL (fn () => |
46 fun use_file pr verbose name = CRITICAL (fn () => |
46 (secure_mltext (); orig_use_file pr verbose name)); |
47 (secure_mltext (); orig_use_file pr verbose name)); |
47 |
48 |
48 fun use name = CRITICAL (fn () => use_file Output.ml_output true name); |
49 fun use name = use_file Output.ml_output true name; |
|
50 |
|
51 fun use_noncritical name = |
|
52 (secure_mltext (); orig_use_file Output.ml_output true name); |
49 |
53 |
50 (*commit is dynamically bound!*) |
54 (*commit is dynamically bound!*) |
51 fun commit () = CRITICAL (fn () => orig_use_text "" Output.ml_output false "commit();"); |
55 fun commit () = CRITICAL (fn () => orig_use_text "" Output.ml_output false "commit();"); |
52 |
56 |
53 |
57 |
61 fun execute s = CRITICAL (fn () => (secure_shell (); orig_execute s)); |
65 fun execute s = CRITICAL (fn () => (secure_shell (); orig_execute s)); |
62 fun system s = CRITICAL (fn () => (secure_shell (); orig_system s)); |
66 fun system s = CRITICAL (fn () => (secure_shell (); orig_system s)); |
63 |
67 |
64 end; |
68 end; |
65 |
69 |
|
70 (*override previous toplevel bindings!*) |
66 val use_text = Secure.use_text; |
71 val use_text = Secure.use_text; |
67 val use_file = Secure.use_file; |
72 val use_file = Secure.use_file; |
68 val use = Secure.use; |
73 val use = Secure.use; |
69 val execute = Secure.execute; |
74 val execute = Secure.execute; |
70 val system = Secure.system; |
75 val system = Secure.system; |