Tcl Source Code

Check-in [fa68f46146]
Login
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Making it possible for http -command callbacks to safely uset the state array.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk | scriptics-tclpro-1-2-b1
Files: files | file ages | folders
SHA1: fa68f46146a5c52584cc82ea8750526c862ad145
User & Date: welch 1999-01-19 23:30:54
Context
1999-01-29
00:32
Added -pipe option if gcc is being used. check-in: 42c3f8c600 user: rjohnson tags: trunk
1999-01-19
23:30
Making it possible for http -command callbacks to safely uset the state array. check-in: fa68f46146 user: welch tags: trunk, scriptics-tclpro-1-2-b1
1999-01-12
02:50
Updated changes. check-in: ee3af272c1 user: rjohnson tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to library/http/http.tcl.

5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101


102

103
104
105
106
107
108
109
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.3 1998/09/14 18:40:03 stanton Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}


	unset state(-command)

    }
}

# http::reset --
#
#	See documentaion for details.
#






|







 







>
>
|
>







5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.4 1999/01/19 23:30:54 welch Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}
	if {[info exist state(-command)]} {
	    # Command callback may already have unset our state
	    unset state(-command)
	}
    }
}

# http::reset --
#
#	See documentaion for details.
#

Changes to library/http2.0/http.tcl.

5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101


102

103
104
105
106
107
108
109
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.3 1998/09/14 18:40:03 stanton Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}


	unset state(-command)

    }
}

# http::reset --
#
#	See documentaion for details.
#






|







 







>
>
|
>







5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.4 1999/01/19 23:30:54 welch Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}
	if {[info exist state(-command)]} {
	    # Command callback may already have unset our state
	    unset state(-command)
	}
    }
}

# http::reset --
#
#	See documentaion for details.
#

Changes to library/http2.1/http.tcl.

5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101


102

103
104
105
106
107
108
109
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.3 1998/09/14 18:40:03 stanton Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}


	unset state(-command)

    }
}

# http::reset --
#
#	See documentaion for details.
#






|







 







>
>
|
>







5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.4 1999/01/19 23:30:54 welch Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}
	if {[info exist state(-command)]} {
	    # Command callback may already have unset our state
	    unset state(-command)
	}
    }
}

# http::reset --
#
#	See documentaion for details.
#

Changes to library/http2.3/http.tcl.

5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101


102

103
104
105
106
107
108
109
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.3 1998/09/14 18:40:03 stanton Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}


	unset state(-command)

    }
}

# http::reset --
#
#	See documentaion for details.
#






|







 







>
>
|
>







5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
..
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#	the Safesock security policy.  These procedures use a 
#	callback interface to avoid using vwait, which is not 
#	defined in the safe base.
#
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: http.tcl,v 1.4 1999/01/19 23:30:54 welch Exp $

package provide http 2.0	;# This uses Tcl namespaces

namespace eval http {
    variable http

    array set http {
................................................................................
    if {[info exists state(-command)]} {
	if {[catch {eval $state(-command) {$token}} err]} {
	    if {[string length $errormsg] == 0} {
		set state(error) [list $err $errorInfo $errorCode]
		set state(status) error
	    }
	}
	if {[info exist state(-command)]} {
	    # Command callback may already have unset our state
	    unset state(-command)
	}
    }
}

# http::reset --
#
#	See documentaion for details.
#