|
|||||||||
![]() |
|||||||||
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: Possible bug in cronolog-jumbo-patch.txt
David, Thanks for point this out. You're right; that is a bug in my patch, which I think I introduced while debugging some umask issues. Some annoyed internal users at Looksmart pointed this out recently as well. I'll patch the patch and issue a new patch, but I would also love feedback from the list on whether there are any good reasons not to add a command line option to override the configure time constant. I cant think of any. Also, if there is sufficient interest and if Andrew is willing to post it, I'll put together a tar ball of the patched version. While I'm at it I need to update the man page to include the new options introduced by the jumbo patch. I wont get to any of this till late next week though. Later, Matt On Jun 25 1414, David White wrote: > I greatly appreciate the work that's gone into Cronolog over the years, > Andrew - I've been benefiting from it for a long time now. And I > appreciate your jumbo patch, Matthew - it took care of some of the > quirks that Solaris had dealing with cronolog. > > I've noticed what might be a bug in cronolog-jumbo-patch.txt (or is it a > necessary change? I only dabble in C, so I can't be sure). The > FILE_MODE definition is now ignored, and created logfiles are now > hardcoded to mode 0700. > > i.e. the patch makes these two substituions to cronolog.c: > > ------------------------------------------------------------------------ > --- > - log_fd = open(pfilename, O_WRONLY|O_CREAT|O_APPEND, FILE_MODE); > + log_fd = openwrapper(pfilename); > > - log_fd = open(pfilename, O_WRONLY|O_CREAT|O_APPEND, FILE_MODE); > + log_fd = openwrapper(pfilename); > ------------------------------------------------------------------------ > --- > > then later, the new openwrapper function performs these calls > irrespective of the FILE_MODE setting > > ------------------------------------------------------------------------ > --- > return open(ofilename, OPEN_SHARED, S_IRWXU ); > > ret = open(ofilename, OPEN_SHARED, S_IRWXU ); > ------------------------------------------------------------------------ > --- > > The result is that logfiles will always be set to 0700. I tried > changing "S_IRWXU" to "FILE_MODE" in the two places it occurs in the > patch, and my early testing seems to indicate that fixed the problem (I > had defined FILE_MODE to 0644, and my logfiles now show -rw-r--r-- ). I > thought I'd pass this on to you guys in case the patch needs to be > patched. > > Thanks again for your work! > > --- > Outgoing mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.711 / Virus Database: 467 - Release Date: 6/25/2004 > -- ####################################################################### # Matt Grosso cell (201)780-9592 mgrosso@xxxxxxxxxxxxx # # work ny (212)324-1904 fax ny (212)324-1910 work sf (415)348-7756 # # pgp public key is at http://www.falconweb.com/~mattg/publickey.pgp # #######################################################################
|