--- image.module-orig	2009-04-05 15:54:18.000000000 -0400
+++ image.module	2009-04-05 15:54:01.000000000 -0400
@@ -625,13 +625,21 @@
 
   $image_info = image_get_info(file_create_path($node->images[$label]));
   $attributes['class'] = "image image-$label ". (isset($attributes['class']) ? $attributes['class'] : "");
-  // Only output width/height attributes if image_get_info() was able to detect
-  // the image dimensions, since certain browsers interpret an empty attribute
-  // value as zero.
-  if (!empty($image_info['width'])) {
+  // Only output width/height attributes if they weren't already provided and
+  // image_get_info() was able to detect the image dimensions, since certain
+  // browsers interpret an empty attribute value as zero.
+  if (isset($attributes['width'])) {
+    if (empty($attributes['width'])) {
+      unset($attributes['width']);
+    }
+  } elseif (!empty($image_info['width'])) {
     $attributes['width'] = $image_info['width'];
   }
-  if (!empty($image_info['height'])) {
+  if (isset($attributes['height']))
+    if (empty($attributes['height'])) {
+      unset($attributes['height']);
+    }
+  } elseif (!empty($image_info['height'])) {
     $attributes['height'] = $image_info['height'];
   }
 
