]> granicus.if.org Git - apache/commitdiff
style
authorAndré Malo <nd@apache.org>
Wed, 20 Aug 2003 01:11:11 +0000 (01:11 +0000)
committerAndré Malo <nd@apache.org>
Wed, 20 Aug 2003 01:11:11 +0000 (01:11 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101029 13f79535-47bb-0310-9956-ffa450edef68

modules/mappers/mod_rewrite.c

index 7586bda8552b4f107d8d67984564d9c078d22c69..1b0176734ad9a42195adf477462c0393415a2764 100644 (file)
@@ -4525,17 +4525,17 @@ static int hook_mimetype(request_rec *r)
 {
     const char *t;
 
-    /* now check if we have to force a MIME-type */
     t = apr_table_get(r->notes, REWRITE_FORCED_MIMETYPE_NOTEVAR);
-    if (t == NULL) {
-        return DECLINED;
-    }
-    else {
+
+    if (t && *t) {
         rewritelog((r, 1, NULL, "force filename %s to have MIME-type '%s'",
                     r->filename, t));
+
         ap_set_content_type(r, t);
         return OK;
     }
+
+    return DECLINED;
 }
 
 /* check whether redirect limit is reached */