ms_fnmatch test program
[tridge/junkcode.git] / mksparse.c
1 #include <unistd.h>
2 #include <stdio.h>
3 #include <fcntl.h>
4
5 int main(int argc, char *argv[])
6 {
7         char *fname = argv[1];
8         off_t megs = atoi(argv[2]);
9         int fd;
10
11         fd = open(fname,O_WRONLY|O_CREAT|O_TRUNC, 0600);
12         lseek(fd, megs * 1024*1024, SEEK_SET);
13         write(fd, fname, strlen(fname));
14         close(fd);
15         return 0;
16 }