Update NEWS for 1.6.22
[pkg-k5-afs_openafs.git] / src / WINNT / afs_setup_utils / afsrm.c
blobc0d1e60032bf62343723fc5bd9197974776a5d16
1 /*
2 * Copyright 2000, International Business Machines Corporation and others.
3 * All Rights Reserved.
5 * This software has been released under the terms of the IBM Public
6 * License. For details, see the LICENSE file in the top-level source
7 * directory or online at http://www.openafs.org/dl/license10.html
8 */
10 /* Utility to forcibly remove AFS software without using InstallShield */
12 #include <afs/param.h>
13 #include <afs/stds.h>
14 #include <afs/cmd.h>
16 #include <windows.h>
17 #include <stddef.h>
18 #include <stdlib.h>
19 #include <stdio.h>
20 #include <string.h>
21 #include <errno.h>
23 #include "forceremove.h"
26 static int DoClient34(struct cmd_syndesc *as, void *arock)
28 DWORD status = Client34Eradicate(FALSE);
30 if (status == ERROR_SUCCESS) {
31 printf("Client 3.4a removal succeeded\n");
32 } else {
33 printf("Client 3.4a removal failed (%d)\n", (int)status);
35 return 0;
38 static void
39 SetupCmd(void)
41 struct cmd_syndesc *ts;
43 ts = cmd_CreateSyntax("client34", DoClient34, NULL,
44 "remove AFS 3.4a client");
48 int main(int argc, char *argv[])
50 int code;
52 /* initialize command syntax */
53 initialize_CMD_error_table();
54 SetupCmd();
56 /* execute command */
57 code = cmd_Dispatch(argc, argv);
59 return (code);