Re: missing fclose someplace?

From: Akuma/Chris Baggett/DOOMer (doomer@BAYOU.COM)
Date: 10/23/97


Change the following block of lines in that function, as shown:

   sprintf(buf, "save/%d.save", i);
-   fopen(buf, "wb");
-   fclose(fll);

-   fll = fopen(buf, "wb");
+  if (!(fll = fopen(buf, "wb")))
+     { sprintf(buf, "Error opening file 'save/%d.save'", i);
+       log(buf);
+    // log("Error opening file '%s'", buf);  // use this if you have the
logf() func
+       return;
+     }
   save_save(world[i].contents, fll);

   fclose(fll);

that should fix it.

have fun :-P

Akuma the Raging Coder

  +------------------------------------------------------------+
  | "The poets talk about love, but what I talk about is DOOM, |
  |      because in the end, DOOM is all that counts." -       |
  |   Alex Machine/George Stark/Stephen King, The Dark Half    |
  |        "Nothing is IMPOSSIBLE, Just IMPROBABLE"            |
  |   "Easier Said Than Done, But Better Done Than Said..."    |
  +------------------------------------------------------------+


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST