Wireshark-commits: [Wireshark-commits] master-2.0 b9f820f: localtime() can return NULL, even if it'
From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Sat, 22 Oct 2016 00:10:56 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=b9f820f39d35ad6f31927c9980835491bac1ee58
Submitter: Guy Harris (guy@xxxxxxxxxxxx)
Changed: branch: master-2.0
Repository: wireshark

Commits:

b9f820f by Guy Harris (guy@xxxxxxxxxxxx):

    localtime() 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 1374109.
    
    Change-Id: Ib18566d1a75e4109adb21834b157e87532fcac10
    Reviewed-on: https://code.wireshark.org/review/18365
    Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
    (cherry picked from commit 49cf42c571f3f94632957371ccd99533e71764ff)
    Reviewed-on: https://code.wireshark.org/review/18367
    

Actions performed:

    from  17b9680   gmtime() can return NULL, even if it's unlikely.
    adds  b9f820f   localtime() can return NULL, even if it's unlikely.


Summary of changes:
 ui/qt/import_text_dialog.cpp |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)