Mercurial > urweb
annotate tests/updateErr.ur @ 2166:8a01e8f21de9
Make OpenSSL usage thread-safe (closes #206)
Enable OpenSSL?s multithreading support by defining locking and
thread-ID callbacks. Remove a lock obviated by this change.
author | Benjamin Barenblat <bbaren@mit.edu> |
---|---|
date | Thu, 06 Aug 2015 10:15:53 -0400 |
parents | abb0e95dcaa1 |
children |
rev | line source |
---|---|
adamc@729 | 1 fun main () : transaction page = |
adamc@729 | 2 s <- source ""; |
adamc@729 | 3 b <- Buffer.create; |
adamc@729 | 4 txt <- source ""; |
adamc@729 | 5 |
adamc@729 | 6 return <xml><body onload={onError (fn xml => Buffer.write b (show xml)); |
adamc@729 | 7 onFail (fn s => alert ("FAIL! " ^ s))}> |
adamc@729 | 8 <dyn signal={s <- signal s; return <xml>{[s]}</xml>}/><br/> |
adamc@729 | 9 <dyn signal={s <- signal s; if s = "" then return <xml>Init</xml> else error <xml>Crapky</xml>}/><br/> |
adamc@729 | 10 <dyn signal={s <- signal s; return <xml>"{[s]}"</xml>}/><br/> |
adam@1890 | 11 <button onclick={fn _ => debug "88"}/><br/> |
adamc@729 | 12 |
adam@1890 | 13 <ctextbox source={txt}/> <button onclick={fn _ => s' <- get txt; set s s'; set txt ""}/> |
adamc@729 | 14 |
adamc@729 | 15 <hr/> |
adamc@729 | 16 |
adamc@729 | 17 <dyn signal={Buffer.render b}/> |
adamc@729 | 18 </body></xml> |