C++ compilation.
[idzebra-moved-to-github.git] / dfa / agrep.c
index f63e7da..39d0f69 100644 (file)
@@ -1,10 +1,19 @@
 /*
- * Copyright (C) 1994, Index Data I/S 
+ * Copyright (C) 1994-1999, Index Data
  * All rights reserved.
  * Sebastian Hammer, Adam Dickmeiss
  *
  * $Log: agrep.c,v $
- * Revision 1.9  1996-10-29 13:57:18  adam
+ * Revision 1.12  1999-05-26 07:49:12  adam
+ * C++ compilation.
+ *
+ * Revision 1.11  1999/02/02 14:50:03  adam
+ * Updated WIN32 code specific sections. Changed header.
+ *
+ * Revision 1.10  1997/09/09 13:37:57  adam
+ * Partial port to WIN95/NT.
+ *
+ * Revision 1.9  1996/10/29 13:57:18  adam
  * Include of zebrautl.h instead of alexutil.h.
  *
  * Revision 1.8  1996/01/08 09:09:16  adam
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
-#include <unistd.h>
 
+#ifdef WIN32
+
+#include <io.h>
+
+#else
+#include <unistd.h>
+#endif
 
 #include <zebrautl.h>
 #include <dfa.h>
@@ -271,6 +286,7 @@ char **argv;
         return i;
     while (--argc > 0)
         if (**++argv != '-' && **argv)
+        {
             if (!pattern)
             {
                 pattern = *argv;
@@ -296,6 +312,7 @@ char **argv;
                 if (i)
                     return i;
             }
+        }
     if (!no)
     {
         fprintf (stderr, "usage:\n "