load_zones

From: Edward J Glamkowski (eglamkowski@angelfire.com)
Date: 04/17/02


I grab a few of the zones from the ftp site and am trying to put
them in, but appearently stuff changed in load_zones() since these
areas were made.  Anyways, what has me particularly perplexed is
the following bit of code:

  while (get_line(fl, buf))
    if ((strchr("MOPGERD", buf[0]) && buf[1] == ' ') || (buf[0] == 'S' && buf[1] == '\0'))
      num_of_cmds++;

  rewind(fl);


What worries me about this is, under MSVC6 on Win98 anyways,
after executing the rewind(fl), it goes back to the top of the
while loop, even though the rewind() is not (that I can see) part
of the while loop.

That is, it behaves like:

  while (get_line(fl, buf)) {
    if ((strchr("MOPGERD", buf[0]) && buf[1] == ' ') || (buf[0] == 'S' && buf[1] == '\0'))
      num_of_cmds++;

  rewind(fl);
  }

even though it is written like:

  while (get_line(fl, buf)) {
    if ((strchr("MOPGERD", buf[0]) && buf[1] == ' ') || (buf[0] == 'S' && buf[1] == '\0'))
      num_of_cmds++;
  }
  rewind(fl);


What am I not understanding here?



Is your boss reading your email? ....Probably
Keep your messages private by using Lycos Mail.
Sign up today at http://mail.lycos.com

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   | Newbie List:  http://groups.yahoo.com/group/circle-newbies/   |
   +---------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 06/25/03 PDT