Re: [ovs-dev] [PATCH 03/10] windows: add includes to daemon-windows

2017-04-18 Thread Alin Serdean
> -Original Message- > From: Ben Pfaff [mailto:b...@ovn.org] > Sent: Wednesday, April 19, 2017 7:46 AM > To: Alin Serdean > Cc: d...@openvswitch.org > Subject: Re: [ovs-dev] [PATCH 03/10] windows: add includes to daemon- > windows > > On Wed, Apr 19, 201

Re: [ovs-dev] [PATCH 03/10] windows: add includes to daemon-windows

2017-04-18 Thread Ben Pfaff
On Wed, Apr 19, 2017 at 03:07:03AM +, Alin Serdean wrote: > > > -fprintf(filep_pidfile, "%d\n", _getpid()); > > > +fprintf(filep_pidfile, "%d\n", getpid()); > > > > This seems reasonable to me, except that usual practice would be more like > > this: > > fprintf(filep_pidfile, "%ld\

Re: [ovs-dev] [PATCH 03/10] windows: add includes to daemon-windows

2017-04-18 Thread Alin Serdean
> > -fprintf(filep_pidfile, "%d\n", _getpid()); > > +fprintf(filep_pidfile, "%d\n", getpid()); > > This seems reasonable to me, except that usual practice would be more like > this: > fprintf(filep_pidfile, "%ld\n", (long int) getpid()); because pid_t might > be > short or int or long

Re: [ovs-dev] [PATCH 03/10] windows: add includes to daemon-windows

2017-04-14 Thread Ben Pfaff
On Mon, Feb 06, 2017 at 04:41:40AM +, Alin Serdean wrote: > Add fatal-signal.h include since it uses: fatal_signal_atexit_handler > and fatal_signal_add_hook > > Use the defined getpid() function and also include since > it is defined in include/windows/unistd.h . > > Signed-off-by: Alin Gab

Re: [ovs-dev] [PATCH 03/10] windows: add includes to daemon-windows

2017-03-07 Thread Sairam Venugopal
Why should _getpid() be replaced with the other function? Thanks, Sairam On 2/5/17, 8:41 PM, "ovs-dev-boun...@openvswitch.org on behalf of Alin Serdean" wrote: >Add fatal-signal.h include since it uses: fatal_signal_atexit_handler >and fatal_signal_add_hook > >Use the defined getpid() func