2
* Copyright (C) 2002-2005 Novell/SUSE
4
* This program is free software; you can redistribute it and/or
5
* modify it under the terms of the GNU General Public License as
6
* published by the Free Software Foundation, version 2 of the
13
#include <sys/types.h>
15
#include <sys/mount.h>
18
int main(int argc, char *argv[])
21
fprintf(stderr, "usage: %s [mount|umount] loopdev mountpoint\n",
26
if (strcmp(argv[1], "mount") == 0) {
27
if (mount(argv[2], argv[3], "ext2", 0xc0ed0000 | MS_MANDLOCK, NULL ) == -1) {
28
fprintf(stderr, "FAIL: mount %s on %s failed - %s\n",
33
} else if (strcmp(argv[1], "umount") == 0) {
34
if (umount(argv[3]) == -1) {
35
fprintf(stderr, "FAIL: umount %s failed - %s\n",
41
fprintf(stderr, "usage: %s [mount|umount] loopdev mountpoint\n",