[comp.unix.wizards] getdate

dave@lsuc.uucp (David Sherman) (04/28/88)

We have getdate(3) installed in libc.a and use it for various
applications beyond netnews.  According to getdate.y, it's
version 2.16, 9/24/87.

I just discovered that it is WRONG when parsing ctime(3) output.

If you feed "Wed Apr 27 12:09:03 1988" to getdate, it interprets
it as a number that, when output through ctime(3), produces:
"Tue Apr 26 11:41:03 1988".

I've reverted to an older getdate I had lying around, version 2.5
(Bellovin 3/3/83), and it works fine.  But the new one has some
enhancements I like.  Does anyone know what the problem is?
This machine is a Perkin-Elmer 3220 running v7, by the way.

David Sherman
The Law Society of Upper Canada
-- 
{ uunet!mnetor  pyramid!utai  decvax!utcsri  ihnp4!utzoo } !lsuc!dave

m5@lynx.uucp (Mike McNally) (03/22/89)

The getdate() library routine is documented with my copy of 4.3 (Integrated
"Solutions"), but does not appear to be there (a library called libu.a is
missing).  Is getdate() in the public domain?  I'd love to have it if it
is (I'd love to have it if it isn't, but that would mean trying to wring
it out of the Integrated Solutions Software Destruction Department).


-- 
Mike McNally                                    Lynx Real-Time Systems
uucp: {voder,athsys}!lynx!m5                    phone: 408 370 2233

            Where equal mind and contest equal, go.

smb@ulysses.homer.nj.att.com (Steven M. Bellovin) (03/23/89)

In article <5339@lynx.UUCP>, m5@lynx.uucp (Mike McNally) writes:
> The getdate() library routine is documented with my copy of 4.3 (Integrated
> "Solutions"), but does not appear to be there (a library called libu.a is
> missing).  Is getdate() in the public domain?  I'd love to have it if it
> is (I'd love to have it if it isn't, but that would mean trying to wring
> it out of the Integrated Solutions Software Destruction Department).

I wrote getdate() many years ago, and did not choose to assert a copyright
at that time.  Given the laws in effect then, that makes it public domain.
I really don't remember if I thought through the issue back then, but I
doubt I would have done anything differently if I had.

What is necessary, of course, is for someone to rewrite the routine; it
was built for v6 yacc, and doesn't use many newer features that would
make the code far more comprehensible.  It's really an unreadable mess.

Anyway, you probably have the code already; it's part of the netnews
source distribution.


		--Steve Bellovin