Comment 20 for bug 589236

Revision history for this message
In , Bzbarsky (bzbarsky) wrote :

I'm not sure I follow this patch. Apart from crashing when miByExt is null, what happens? Currently, if miByExt has a default handler there are two options:

1) Have a retval. In this case, we CopyBasicDataTo and return miByExt.
2) No retval. In this case we're hitting the SetMIMEType code already.

So the patch only affects behavior in the case when we have both retval and miByExt. But all it changes is to call SetMIMEType instead of CopyBasicDataTo,

Is CopyBasicDataTo clobbering the default app somehow in this case?

As far as the "right thing" bit, the point of this function is to use both type and extension to get our best guess of how to handle. So we certainly want to use the default app for the extension if there isn't one for the type!