Changeset b56c94e in tol
- Timestamp:
- Jul 1, 2010, 4:44:28 PM (16 years ago)
- Branches:
- 1941-docker-image-to-test, devel, master
- Children:
- 7312814
- Parents:
- 3e37515
- Location:
- tol/stdlib/general/system
- Files:
-
- 1 added
- 1 deleted
- 1 edited
- 2 moved
-
Curl/TolCurl.tcl (deleted)
-
CurlApi/CurlApi.tol (moved) (moved from tol/stdlib/general/system/Curl/Curl.tol) (1 diff)
-
CurlApi/CurlFunctions.tol (moved) (moved from tol/stdlib/general/system/Curl/CurlFunctions.tol) (2 diffs)
-
CurlApi/TolCurl.tcl (added)
-
_init_system.tol (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
tol/stdlib/general/system/CurlApi/CurlApi.tol
r3e37515 rb56c94e 6 6 7 7 ////////////////////////////////////////////////////////////////////////////// 8 NameBlock Curl = [[8 NameBlock CurlApi = [[ 9 9 ////////////////////////////////////////////////////////////////////////////// 10 10 Text _.autodoc.brief = "Curl API"; -
tol/stdlib/general/system/CurlApi/CurlFunctions.tol
r3e37515 rb56c94e 17 17 }; 18 18 19 Real Get( NameBlock args )19 Set GetUrl( NameBlock args ) 20 20 { 21 21 // Esta inicializacion deberia desaparecer … … 25 25 Text file = args::file; 26 26 // otros argumentos opcionales seran tratados mas adelante 27 Set cmd = [[ "::TolCurl::Get", url, file ]]; 27 Real verbose = getOptArg( args, "verbose", 0 ); 28 Set cmd = [[ "::TolCurl::getUrl", url, file ]]; 28 29 Set tclResult = Tcl_EvalEx( cmd ); 29 30 Real status = tclResult["status"]; 30 Real If( status, { 31 Real curlStatus = TextToReal( tclResult["result"] ); 32 If( curlStatus, { 33 Set curlErrorMsg = 34 Tcl_EvalEx( [[ "::curl::easystrerror", tclResult["result"] ]] ); 35 Error( "Curl::Get: " + curlErrorMsg["result"] ); 36 Real 0 37 }, 1 /* Get OK */ ) 31 Set If( status, { 32 Set curlResult = { 33 Eval( tclResult["result"] ) 34 } 38 35 }, { 39 Error( "Curl::Get: " + tclResult[ "result"] );40 Real 0/* Tcl Code is wrong!!! */36 Error( "Curl::Get: " + tclResult[ "result" ] ); 37 Set Copy( Empty ) /* Tcl Code is wrong!!! */ 41 38 } ) 42 39 }; -
tol/stdlib/general/system/_init_system.tol
r3e37515 rb56c94e 10 10 Set Include("cmsg/_init_cmsg.tol"); 11 11 12 Set Include("Curl /Curl.tol");12 Set Include("CurlApi/CurlApi.tol"); 13 13 Set Include("PackArchive/PackArchive.tol"); 14 14
Note: See TracChangeset
for help on using the changeset viewer.
