Wireshark-commits: [Wireshark-commits] master-2.2 0cf4731: gmtime() can return NULL, even if it's u

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Fri, 21 Oct 2016 22:50:22 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=0cf4731dd7d1dfc13ac261b1b761df04e821cd85
Submitter: Guy Harris (guy@xxxxxxxxxxxx)
Changed: branch: master-2.2
Repository: wireshark

Commits:

0cf4731 by Guy Harris (guy@xxxxxxxxxxxx):

    gmtime() can return NULL, even if it's unlikely.
    
    ANSI C says it can return NULL - and, at least on Windows with the MSVC
    library, it *will* return null for dates prior to the Epoch.  Check for
    a null return and handle it.
    
    Fixes CID 1374110.
    
    Change-Id: I78bf92cfbb94a86544442269cc3b53338eb19778
    Reviewed-on: https://code.wireshark.org/review/18361
    Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
    (cherry picked from commit 362b83f44a4a6a731c64f8a6591ee717af2454a0)
    Reviewed-on: https://code.wireshark.org/review/18362
    

Actions performed:

    from  8fc0f73   Clean up file handle management.
    adds  0cf4731   gmtime() can return NULL, even if it's unlikely.


Summary of changes:
 epan/dissectors/packet-cip.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)