From: SourceForge.net <no...@so...> - 2004-01-23 04:40:33
|
Patches item #875701, was opened at 2004-01-12 13:56 Message generated for change (Comment added) made by davygrvy You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=310894&aid=875701&group_id=10894 Category: 25. Channel System Group: None Status: Open Resolution: None Priority: 5 Submitted By: David Gravereaux (davygrvy) Assigned to: Andreas Kupries (andreas_kupries) Summary: ver 4 update for Tcl_ChannelType to support cut/splice Initial Comment: Initial patch.. work in progress, aiming for inclusion in 8.5.0 ---------------------------------------------------------------------- >Comment By: David Gravereaux (davygrvy) Date: 2004-01-22 20:40 Message: Logged In: YES user_id=7549 This patch is not safe to use in its current form. I've found a bug i'm re-evaluating, a watchmask issue I need to solve. ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-16 12:03 Message: Logged In: YES user_id=7549 Your note about checking HaveVersion was right. It will work in the forward direction, a v3 loaded into a core that understands up to v4, but not the other way. ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-16 12:00 Message: Logged In: YES user_id=7549 Just discovered something interesting. If I create a v4 driver in an extension and load it into 8.4, Tcl_ChannelVersion incorrectly returns TCL_CHANNEL_VERSION_1 rather than TCL_CHANNEL_VERSION_3 The proper logic, I think would be to add a ceiling expecting more revisions in the future. Example: Tcl_ChannelTypeVersion Tcl_ChannelVersion(chanTypePtr) Tcl_ChannelType *chanTypePtr; /* Pointer to channel type. */ { if (chanTypePtr->version == TCL_CHANNEL_VERSION_2) { return TCL_CHANNEL_VERSION_2; } else if (chanTypePtr->version == TCL_CHANNEL_VERSION_3) { return TCL_CHANNEL_VERSION_3; } else if (chanTypePtr->version == TCL_CHANNEL_VERSION_4) { return TCL_CHANNEL_VERSION_4; /* reserve this space for future revisions. */ } else if (chanTypePtr->version < 15) { return TCL_CHANNEL_VERSION_4; } else { /* * In <v2 channel versions, the version field is occupied * by the Tcl_DriverBlockModeProc */ return TCL_CHANNEL_VERSION_1; } } ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-13 19:13 Message: Logged In: YES user_id=7549 Final patch ready that includes doc changes. Things to note: 1) transformChannelType of generic/tclIOGT.c had the version set to 2, not 3. It is setting a wideSeekProc. Is 3 or 2 the correct version? 2) *ALL* channel drivers that maintain any tsd data are all now at version 4. This includes every win channel type, now. Not just restricted to file and socket. 3) HaveVersion() should be fine, re. email note. 4) All internal channel types are at or greater than v2. Even the mac/ ones that no longer are maintained by anyone. 5) Do a 'make genstubs' after applying patch. 6) all tests pass for a threaded build of Tcl. Does testthread do a transfer test and are there test cases? I haven't looked yet. ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-13 13:58 Message: Logged In: YES user_id=7549 rev #3 patch ready. ---------------------------------------------------------------------- Comment By: Donal K. Fellows (dkf) Date: 2004-01-13 02:16 Message: Logged In: YES user_id=79902 David, please don't set Status to Pending since it means that it is Pending Deletion if further information is not supplied. Which is not what you meant at all! ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-13 01:58 Message: Logged In: YES user_id=7549 Andreas, Could you have a look at this? Am I on-track? It looks complete to me ('cept for docs). How does it look to you? ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-12 16:48 Message: Logged In: YES user_id=7549 Note to self: add Tcl_DriverCutProc and Tcl_DriverSpliceProc to the Tcl_Channel man page. ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-12 16:47 Message: Logged In: YES user_id=7549 Untested on unix and mac, but those area where touched by the patch and needs testers. ---------------------------------------------------------------------- Comment By: David Gravereaux (davygrvy) Date: 2004-01-12 16:45 Message: Logged In: YES user_id=7549 Only tested on Win2K. All tests pass for rev#2 !!! ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=310894&aid=875701&group_id=10894 |