Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!wuarchive!sdd.hp.com!hplabs!hpcc05!hpcuhb!hpindda!mas From: mas@hpindda.cup.hp.com (Margie Spencer) Newsgroups: comp.sys.hp Subject: Re: Porting a program from Sun: async I/O under hp-ux? Message-ID: <4310148@hpindda.cup.hp.com> Date: 6 Dec 90 00:50:56 GMT References: <1990Dec4.000843.1500@polyof.poly.edu> Organization: HP Information Networks, Cupertino, CA Lines: 23 >My problem is that the program makes these calls: > >fcntl(fd, F_SETFL, FASYNC) and fcntl(fd, F_SETOWN, getpid()) > >FASYNC and F_SETOWN aren't defined for hp-ux. > .... > Willard This is deja-vu! I just got finished helping someone with a very similar problem. Try this ... 1) For the equivalent of F_SETOWN try ... int pgrp = -getpid(); ioctl(sock, SIOCSGRP, &pgrp) 2) For the equivalent of FASYNC try ... int flag = 1; ioctl(sock,FIOASYNC,&flag)