Bringing ChocolateCaste-0.7 into the main branch.
[AROS-Contrib.git] / bgui / KillBGUI.c
blobeec84603f3535d46fae0cf081ad46223381d5b26
1 /*
2 * @(#) $Header$
4 * KillBGUI.c
6 * This program will flush bgui.library out of memory, if this is not possible;
7 * then the existing one is renamed "bgui.flushed" so it will not be found again.
9 * (C) Copyright 1998 Manuel Lemos.
10 * (C) Copyright 1996-1997 Ian J. Einman.
11 * (C) Copyright 1993-1996 Jaba Development.
12 * (C) Copyright 1993-1996 Jan van den Baard.
13 * All Rights Reserved.
15 * $Log$
16 * Revision 42.0 2000/05/09 22:08:00 mlemos
17 * Bumped to revision 42.0 before handing BGUI to AROS team
19 * Revision 41.11 2000/05/09 19:53:33 mlemos
20 * Merged with the branch Manuel_Lemos_fixes.
22 * Revision 41.10 1998/02/25 21:11:21 mlemos
23 * Bumping to 41.10
25 * Revision 1.1 1998/02/25 17:07:05 mlemos
26 * Ian sources
30 /* KillBGUI.c
32 * This program will flush bgui.library out of memory, if this is not possible;
33 * then the existing one is renamed "bgui.flushed" so it will not be found again.
36 #include <proto/exec.h>
37 #include <exec/execbase.h>
38 #include <strings.h>
39 #include <stdio.h>
41 void main(void)
43 struct Node *BGUIBase;
45 AllocMem(0x10000000, 0);
46 Forbid();
47 BGUIBase = FindName(&((struct ExecBase *)SysBase)->LibList, "bgui.library");
48 Permit();
49 if (BGUIBase) strcpy(BGUIBase->ln_Name + 5, "flushed");