Wireshark-bugs: [Wireshark-bugs] [Bug 10868] SMPP packets with out-of-range dates/times can caus
Date: Mon, 19 Jan 2015 01:39:40 +0000

Comment # 8 on bug 10868 from
(In reply to Guy Harris from comment #6)
> (In reply to Bill Meier from comment #4)
> > An actual crash related to an "invalid memory ref" occurs probably only on
> > Windows.
> 
> UN*X localtime() and gmtime() rarely, if ever, return NULL.  MSVC
> localtime() and gmtime(), not so much.


>From my Fedora libc documenation:

    The return value is the null pointer if TIME cannot be represented
     as a broken-down time; typically this is because the year cannot
     fit into an 'int'.

I haven't run the numbers, but I would think that with a gnu C library time_t
being a long int that on an LP64 system there would be some number of time_t
values which would cause localtime() to return NULL because the year wouldn't
fit in an int..


You are receiving this mail because:
  • You are watching all bug changes.