[PD-cvs] externals/ggee/signal streamin~.c, 1.7, 1.8 streamout~.c, 1.4, 1.5

Hans-Christoph Steiner eighthave at users.sourceforge.net
Tue Nov 15 07:16:41 CET 2005


Update of /cvsroot/pure-data/externals/ggee/signal
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26078/signal

Modified Files:
	streamin~.c streamout~.c 
Log Message:
minor compile fixes for Mac OS X and MinGW

Index: streamin~.c
===================================================================
RCS file: /cvsroot/pure-data/externals/ggee/signal/streamin~.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** streamin~.c	14 Nov 2005 21:59:09 -0000	1.7
--- streamin~.c	15 Nov 2005 06:16:39 -0000	1.8
***************
*** 22,27 ****
  #endif
  
! 
! 
  #ifdef _MSC_VER
  #pragma warning( disable : 4244 )
--- 22,26 ----
  #endif
  
! /* these pragmas are only used for MSVC, not MinGW or Cygwin <hans at at.or.at> */
  #ifdef _MSC_VER
  #pragma warning( disable : 4244 )
***************
*** 80,87 ****
  #ifdef unix
      int sockopt = 1;
!      if (setsockopt(sockfd, SOL_TCP, TCP_NODELAY, (const char*) &sockopt, sizeof(int)) < 0)
! 	  DEBUGMESS(post("setsockopt NODELAY failed\n"));
!      else
! 	  DEBUGMESS(post("TCP_NODELAY set"));
       
       /* if we don`t use REUSEADDR we have to wait under unix until the 
--- 79,91 ----
  #ifdef unix
      int sockopt = 1;
! 	 if (setsockopt(sockfd, IPPROTO_TCP, TCP_NODELAY, (const char*) &sockopt, sizeof(int)) < 0) 
! 	 {
! 		 DEBUGMESS(post("setsockopt NODELAY failed\n"));
! 	 }
! 	 else
! 	 {
! 		 DEBUGMESS(post("TCP_NODELAY set"));
! 	 }
! 	 
       
       /* if we don`t use REUSEADDR we have to wait under unix until the 

Index: streamout~.c
===================================================================
RCS file: /cvsroot/pure-data/externals/ggee/signal/streamout~.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** streamout~.c	22 May 2005 20:48:00 -0000	1.4
--- streamout~.c	15 Nov 2005 06:16:39 -0000	1.5
***************
*** 18,21 ****
--- 18,24 ----
  #endif
  
+ #ifdef __APPLE__
+ #include <unistd.h>
+ #endif
  
  /* Utility functions */
***************
*** 203,207 ****
  	 /* send the format tag */
  	 
! #ifdef unix
  		if (send(x->x_fd,(char*)&x->x_tag,sizeof(t_tag),/*MSG_DONTWAIT|*/MSG_NOSIGNAL) < 0)
  #else
--- 206,212 ----
  	 /* send the format tag */
  	 
! #ifdef __APPLE__
! 		if (send(x->x_fd,(char*)&x->x_tag,sizeof(t_tag),SO_NOSIGPIPE) < 0)
! #elif defined unix
  		if (send(x->x_fd,(char*)&x->x_tag,sizeof(t_tag),/*MSG_DONTWAIT|*/MSG_NOSIGNAL) < 0)
  #else
***************
*** 218,222 ****
  	 for (sent = 0; sent < length;) {
  	      int res = 0;
! #ifdef unix
  		  res = send(x->x_fd, bp, length-sent, /*MSG_DONTWAIT|*/MSG_NOSIGNAL);
  #else
--- 223,229 ----
  	 for (sent = 0; sent < length;) {
  	      int res = 0;
! #ifdef __APPLE__
! 		  res = send(x->x_fd, bp, length-sent, SO_NOSIGPIPE);
! #elif defined unix
  		  res = send(x->x_fd, bp, length-sent, /*MSG_DONTWAIT|*/MSG_NOSIGNAL);
  #else





More information about the Pd-cvs mailing list