tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
From: Joerg Bruehe <joerg () sql ! de>
To: tru64-unix-managers
Subject: SUMMARY: setpgrp: Deviation from manual
Date: Wed, 12 Jan 2000 09:22:06 +0000	[thread overview]
Message-ID: <96079271218496.tru64-unix-managers.marc@archive.invalid> (raw)

Greetings ! 

I had asked in this list:
> 
> Dear admins,
> 
> I just encountered a programming problem (Tru64 4.0D):
> 
> According to my understanding of 'man setpgrp',
> this function can be called either without any parameters
> (current standard) or with 2 (old, for backwards compatibility);
> and without parameters it is said not to return any errors
> (= cannot fail).
> 
> I called it without parameters, and I got the return code '-1'
> and the errno value 'ESRCH'.
> 
> So I ask:
> - Did I misunderstand the manual ?
> - Do I need some C "define" to get the no-param-version to work ?

Fast as usual, I got responses from 
   Dr. Thomas P. Blinn    tpb@doctor.zk3.dec.com 
   Serguei Patchkovskii   <patchkov@ucalgary.ca> 
   dsr@mail.lns.cornell.edu   (Daniel S. Riley)
       
They all agree that I need to define _XOPEN_SOURCE_EXTENDED 
as a cpp symbol in order to get the new, parameter-less version 
of 'setpgrp' - I will follow that advice. 

Dr. Thomas P. Blinn also wrote that this "define" will cause 
'setpgrp' to be (internally) renamed to '_Esetpgrp', detectable 
by the 'strings' command (probably 'nm' as well ?) on the linked 
program (and the object module ?). 

Daniel S. Riley also wrote that using '-std1' as a compiler 
option would cause a warning (too few arguments) in such code, 
however I do use that option and get no warnings - there must 
be some other condition missing in my case. 

Again, thank you all for your prompt and helpful responses. 

Regards, 
Joerg Bruehe 

-- 
Joerg Bruehe, SQL Datenbanksysteme GmbH, Berlin, Germany
     (speaking only for himself)
mailto: joerg@sql.de

                 reply	other threads:[~2000-01-12  9:22 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox