dmalcolm cb921e
--- evolution-2.0.2/mail/em-utils.c.fix-145552	2004-09-24 11:49:29.000000000 -0400
dmalcolm cb921e
+++ evolution-2.0.2/mail/em-utils.c	2005-08-02 22:42:04.000000000 -0400
dmalcolm cb921e
@@ -1919,10 +1919,22 @@
dmalcolm cb921e
 	 * try to do better with the filename check.
dmalcolm cb921e
 	 */
dmalcolm cb921e
 	
dmalcolm cb921e
+	/* RH bug 145552:  code based on _gnome_vfs_get_mime_type_internal:
dmalcolm cb921e
+	 * So many file types come compressed by gzip 
dmalcolm cb921e
+	 * that extensions are more reliable than magic
dmalcolm cb921e
+	 * typing. If the file has a suffix, then use
dmalcolm cb921e
+	 * the type from the suffix:
dmalcolm cb921e
+	 */
dmalcolm cb921e
 	if (magic_type) {
dmalcolm cb921e
 		if (name_type
dmalcolm cb921e
 		    && (!strcmp(magic_type, "text/plain")
dmalcolm cb921e
-			|| !strcmp(magic_type, "application/octet-stream")))
dmalcolm cb921e
+			|| !strcmp(magic_type, "application/octet-stream")
dmalcolm cb921e
+ 			|| !strcmp(magic_type, "application/octet-stream")
dmalcolm cb921e
+ 			|| !strcmp(magic_type, "application/x-ole-storage")
dmalcolm cb921e
+ 			|| !strcmp(magic_type, "text/xml")
dmalcolm cb921e
+ 			|| !strcmp(magic_type, "application/x-bzip")
dmalcolm cb921e
+ 			|| !strcmp(magic_type, "application/x-gzip")
dmalcolm cb921e
+ 			|| !strcmp(magic_type, "application/zip")))
dmalcolm cb921e
 			return name_type;
dmalcolm cb921e
 		else
dmalcolm cb921e
 			return magic_type;