Ticket UUID: | 813606 | |||
Title: | Fix bug #813087, "tclsh treats Unix pipelines as sockets" | |||
Type: | Patch | Version: | None | |
Submitter: | cc_benny | Created on: | 2003-09-27 16:30:51 | |
Subsystem: | 27. Channel Types | Assigned To: | andreas_kupries | |
Priority: | 5 Medium | Severity: | ||
Status: | Closed | Last Modified: | 2003-10-24 01:01:48 | |
Resolution: | Accepted | Closed By: | andreas_kupries | |
Closed on: | 2003-10-23 18:01:48 | |||
Description: |
Darwin/Mac OS X (and probably NetBSD) implement pipes as local sockets. That makes tclUnixChan.c:Tcl_MakeFileChannel() detect pipes as sockets, which in turn makes pipes have the wrong default options. This patch is based on <http://groups.google.com/groups?selm=20010327154747.A13991%40vaasje.org>. It replaces getsockopt(SO_TYPE) with getsockname(). | |||
User Comments: |
andreas_kupries added on 2003-10-24 01:01:48:
Logged In: YES user_id=75003 Accepted with small changes: - sockaddr_storage changed to sockaddr - ss_family changed to sa_family - Changed the condition according to J. English's comments in the bug report. Committed to both head and core-8-4-branch. cc_benny added on 2003-09-27 23:34:35: Logged In: YES user_id=143885 I forgot to add: I have tested that this patch doesn't detect pipes as sockets on Mac OS X and Linux. I have not actually tested if it detects real sockets right. cc_benny added on 2003-09-27 23:30:51: File Added - 62720: tclUnixChan.c.patch |
Attachments:
- tclUnixChan.c.patch [download] added by cc_benny on 2003-09-27 23:30:51. [details]