HP OpenVMS Systemsask the wizard | 
	
 The Question is: I tried to include unix file control function fcntl() and associated Macros.But i am not able to link . Please help me in figuring out which Include file to include for using fcntl function. ( I used to fcntl to make socket NON- Blocking). I used Compaq C. The Answer is : 
 
  Though the errors received are unspecified, the OpenVMS Wizard will
  assume these are undefined symbol errors.
 
  As the Compaq C compiler version is unstated, the OpenVMS Wizard
  will assume the use of V6.2 or V6.4.
 
  As for the question, please see the OpenVMS FAQ, as it provides
  information on some of the common C programming mistakes.  Also
  please see the Compaq C and (specifically for socket calls) the
  Compaq C socket API appendix and the TCP/IP Services programming
  documentation; for additional information and for additional details.
 
  The angle brackets used in the following example have been replaced
  by square brackets in deference to web browser viewers.
 
#include [socket.h]
#include [stropts.h]
#include [stdio.h]
 
int main(void)
 
    int fd, tmp;
 
    if ( (fd = socket(AF_INET, SOCK_STREAM, 0)) == -1 )
        perror("socket");
 
    if ( ioctl(fd, FIONBIO, &tmp) == -1 )
        perror("ioctl");
    else
        puts("socket set to non-blocking mode");
 
    return 0;
 
 
 
 
  |