Opened 5 years ago

Closed 5 years ago

#1485296 closed Feature Patches (fixed)

mime type detection not perfect 8)

Reported by: arekm Owned by:
Priority: 5 Milestone: 0.2-beta
Component: PHP backend Version: 0.2-alpha
Severity: normal Keywords:
Cc:

Description

Continuation of #1485222 improvements.

Unfortunately in meantime the code was changed that if finfo_file() fails then whole detection fails :-/

Wouldn't be it better to fallback to other mime detection type in such case?... and if that fails fallback to unknown/unknown.

--- program/include/rcube_shared.inc.org 2008-08-27 14:23:03.814146425 +0200
+++ program/include/rcube_shared.inc 2008-08-27 14:24:23.362054805 +0200
@@ -569,7 +569,7 @@

finfo_close($finfo);

}

}

  • else if (function_exists('mime_content_type')) {

+ if (!$mime_type && function_exists('mime_content_type')) {

$mime_type = mime_content_type($path);

}

Change History (2)

comment:1 Changed 5 years ago by alec

  • Component changed from Client Scripts to PHP backend
  • Milestone changed from later to 0.2-beta

comment:2 Changed 5 years ago by thomasb

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in [35dc0bed]

Note: See TracTickets for help on using tickets.