diff --git a/reviewboard/attachments/forms.py b/reviewboard/attachments/forms.py
index b18ec50e79a370ce27a45338d1a7f8508a6fd9f2..f214abd2dc4e8a561de3d9295f3a6c444b2d18d4 100644
--- a/reviewboard/attachments/forms.py
+++ b/reviewboard/attachments/forms.py
@@ -26,7 +26,15 @@ class UploadFileForm(forms.Form):
 
     def create(self, file, review_request, filediff=None):
         caption = self.cleaned_data['caption'] or file.name
-        mimetype = file.content_type or self._guess_mimetype(file)
+
+        if (not file.content_type or
+            file.content_type == 'application/octet-stream'):
+            # We can't rely on the browser for the file type here, so
+            # attempt to guess it.
+            mimetype = self._guess_mimetype(file)
+        else:
+            mimetype = file.content_type
+
         filename = '%s__%s' % (uuid4(), file.name)
 
         attachment_kwargs = {
