• Guy Harris's avatar
    Fix the calculation of a file's "basename". · f96b094a
    Guy Harris authored
    Strip off only extensions that correspond to file types we know about;
    QFileInfo::baseName() strips off *all* extensions, where "extension" is
    "anything preceded by a .", so it turns foo.bar.pcap.gz into foo, not
    foo.bar.  We don't want that; instead, we strip off only those
    extensions that correspond to file types we know how to read, so we'd
    strip off .pcap.gz in foo.bar.pcap.gz, and strip off .pcap in
    foo.bar.pcap, leaving foo.bar in both cases.
    
    Change-Id: I5385921ad2f0fef815d52e9902fef15735fd9dae
    Reviewed-on: https://code.wireshark.org/review/28636Reviewed-by: 's avatarGuy Harris <guy@alum.mit.edu>
    (cherry picked from commit aab5ad074e88e3c03e438b2b9ff503191c6f6458)
    Reviewed-on: https://code.wireshark.org/review/28637
    f96b094a