date and time created 87/02/15 16:03:30 by lepreau
authorJay Lepreau <lepreau@ucbvax.Berkeley.EDU>
Mon, 16 Feb 1987 08:03:30 +0000 (00:03 -0800)
committerJay Lepreau <lepreau@ucbvax.Berkeley.EDU>
Mon, 16 Feb 1987 08:03:30 +0000 (00:03 -0800)
SCCS-vsn: local/sccscmds/sccscmds.2/util/imatch.c 1.1
SCCS-vsn: local/sccscmds/sccscmds.ok/util/imatch.c 1.1

usr/src/local/sccscmds/sccscmds.2/util/imatch.c [new file with mode: 0644]
usr/src/local/sccscmds/sccscmds.ok/util/imatch.c [new file with mode: 0644]

diff --git a/usr/src/local/sccscmds/sccscmds.2/util/imatch.c b/usr/src/local/sccscmds/sccscmds.2/util/imatch.c
new file mode 100644 (file)
index 0000000..c8b0f73
--- /dev/null
@@ -0,0 +1,15 @@
+static char Sccsid[] "@(#)imatch       2.1";
+/*
+       initial match
+       if `prefix' is a prefix of `string' return 1
+       else return 0
+*/
+
+imatch(prefix,string)
+register char *prefix, *string;
+{
+       while (*prefix++ == *string++)
+               if (*prefix == 0)
+                       return(1);
+       return(0);
+}
diff --git a/usr/src/local/sccscmds/sccscmds.ok/util/imatch.c b/usr/src/local/sccscmds/sccscmds.ok/util/imatch.c
new file mode 100644 (file)
index 0000000..c8b0f73
--- /dev/null
@@ -0,0 +1,15 @@
+static char Sccsid[] "@(#)imatch       2.1";
+/*
+       initial match
+       if `prefix' is a prefix of `string' return 1
+       else return 0
+*/
+
+imatch(prefix,string)
+register char *prefix, *string;
+{
+       while (*prefix++ == *string++)
+               if (*prefix == 0)
+                       return(1);
+       return(0);
+}