Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 449861c1 authored by Albert Astals Cid's avatar Albert Astals Cid

KMimeType::mimeType can return null

parent 9a180848
......@@ -219,12 +219,15 @@ static QString compressedMimeFor( const QString& mime_to_check )
return it.value();
KMimeType::Ptr mime = KMimeType::mimeType( mime_to_check );
if ( mime->is( app_gzip ) )
return app_gzip;
else if ( supportBzip && mime->is( app_bzip ) )
return app_bzip;
else if ( supportXz && mime->is( app_xz ) )
return app_xz;
if ( mime )
{
if ( mime->is( app_gzip ) )
return app_gzip;
else if ( supportBzip && mime->is( app_bzip ) )
return app_bzip;
else if ( supportXz && mime->is( app_xz ) )
return app_xz;
}
return QString();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment