Index: rotating_banner.module
===================================================================
--- rotating_banner.module	(revision 23503)
+++ rotating_banner.module	(working copy)
@@ -487,25 +487,28 @@
 
   
   foreach ($slides as $k => $slide) {
+    $ratioPointer = 0;
+    $smallest = 0;
     $first_slide = FALSE;
     if ($k == 0) {
       $first_slide = TRUE;
     }
 
     $file = file_load($slide->fid);
-    $link = $slide->link;
-    
-    $size = getimagesize($file->uri);
-    if ($size[0] < $smallest || $smallest == NULL) {
-      $smallest = $size[0];
+    if ($file) {
+      $size = getimagesize($file->uri);
+      if ($size[0] < $smallest || $smallest == NULL) {
+        $smallest = $size[0];
+      }
+
+      // Determine if the slide has the smallest w/h ratio
+      if (($size[0]/$size[1]) < $ratio || $ratio == NULL) {
+        $ratio = $size[0]/$size[1];
+        $ratioPointer = $k;
+      }
     }
     
-    // Determine if the slide has the smallest w/h ratio
-    if (($size[0]/$size[1]) < $ratio || $ratio == NULL) {
-      $ratio = $size[0]/$size[1];
-      $ratioPointer = $k;
-    }
-    
+    $link = $slide->link;
     $textboxes = $slide->textboxes;
     $layout = $slide->layout;
 
@@ -534,7 +537,9 @@
   
   // If the banner is fluid or doesn't have a set width, we need to use the width of the narrowest slide that we calculated earlier
   if ($fluid || $settings['width'] <= 0) {
-    $style .= $smallest . "px;";
+    if ($smallest) {
+      $style .= $smallest . "px;";
+    }
     $element['#prefix'] = $element['#prefix'] . '" style="' . $style . '">' . "\n\t";
   } else {
     
