From: nobody <no...@so...> - 2001-02-26 22:56:56
|
Artifact #219185, was updated on 2000-10-25 22:03 You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=110894&aid=219185&group_id=10894 Category: dde Package Group: 8.1.1 Status: Open Priority: 5 Submitted By: Nobody/Anonymous Assigned to: Kevin B KENNY Summary: dde only handles UTF-8 data (-binary patch available) Initial Comment: OriginalBugID: 2276 Bug Version: 8.1.1 SubmitDate: '1999-06-22' LastModified: '2000-09-07' Severity: MED Status: Assigned Submitter: techsupp ChangedBy: hobbs OS: All Windows Machine: X86 FixedDate: '2000-10-25' ClosedDate: '2000-10-25' Name: Peter Hardie Comments: An optional "-binary" argument has been added to the dde request command to force it to receive binary data rather than a null-terminated string. I don't think there is a reliable way for the program to tell whether the returned data are binary or a string and so the user must tell the program via the optional argument. Users should be aware that it appears that the windows DDE returns a data length of 28 for any data of that length or shorter (even when it is returning a string). They must, therefore, still have some reliable way of determining where the end of the data occurs. In the sample script included at the above URL, the binary data returned by Netscape's WWW_ListWindows topic are terminated by a double word zero (where netscape's double word is 32 bits) and thus even if there are fewer than 6 windows open, the end of the data can be reliably detected. Pete el_...@de... DesiredBehavior: In V1.0 of TCL's DDE package, the "dde request" command cannot handle the case where binary data are returned instead of a null-terminated string. Patch: Two patch versions are available at this URL along with a readme.txt and a small sample script to test the patch once it is installed. http://members.home.net/el.supremo/tcl_files/reqbinary/ PatchFiles: tclwindde.c From Bonnet: Tcl seems to always send the string rep of an object, whatever its internal rep may be (DdeServerProc in win/tclWinDde.c). The result of an encoding converted string is a byte array that holds the converted string, however what is sent is the UTF-8 string. So Tcl should check for the internal rep to see whether it is a byte array and use it instead. On Windows NT, Tcl could also use Unicode instead of ANSI. I believe the same is true when sending data to Tcl: data is sent as ANSI, but Tcl expects UTF-8. Tcl-to-Tcl communication works OK because both expect UTF-8. See also: http://www.deja.com/=dnc/getdoc.xp?AN=666313424 -- 09/07/2000 hobbs ---------------------------------------------------------------------- You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=110894&aid=219185&group_id=10894 |