diff --git a/CMHG/header b/CMHG/header index 4b30a2500b8cf405ebcdd64aa345a91b0508d57e..38989a033a45816e4390fac1cc4f39f132c4c101 100644 --- a/CMHG/header +++ b/CMHG/header @@ -14,7 +14,7 @@ ; title-string: BootCommands -help-string: Boot_Commands 1.14 +help-string: Boot_Commands 1.15 initialisation-code: main_initialise @@ -59,4 +59,9 @@ command-keyword-table: main_command gstrans-map: 0, international:, invalid-syntax: "SafeLogonSyntax", - help-text: "SafeLogonHelp") + help-text: "SafeLogonHelp"), + FreePool( min-args: 0, max-args: 0, + gstrans-map: 0, + international:, + invalid-syntax: "FreePoolSyntax", + help-text: "FreePoolHelp") diff --git a/Resources/Messages b/Resources/Messages index bcb51abe3b0c530d882a5664a80bb902f3e5f624..abb55946416a05641f7daf269ce8b85080ade767 100644 Binary files a/Resources/Messages and b/Resources/Messages differ diff --git a/Resources/UK/Messages b/Resources/UK/Messages index bcb51abe3b0c530d882a5664a80bb902f3e5f624..abb55946416a05641f7daf269ce8b85080ade767 100644 Binary files a/Resources/UK/Messages and b/Resources/UK/Messages differ diff --git a/c/main b/c/main index 31681e4db2029f27ed3eecc8b3e5870b0bb0d4c7..995309e7198a9ac2da6a16ebce2ac80d90afbb26 100644 --- a/c/main +++ b/c/main @@ -628,6 +628,23 @@ finish: return error; } + +static os_error *Free_Pool( char *tail ) +{ + int next_size; + os_error *err = xwimp_slot_size( -1, -1, NULL, &next_size, NULL ); + if ( err == NULL ) + { + int app_size; + err = xos_change_environment( 0x0E, 0, 0, 0, (void **)&app_size, NULL, NULL ); + if ( err == NULL ) err = xos_read_dynamic_area( 6, NULL, NULL, NULL ); + if ( err == NULL ) err = xos_change_dynamic_area( 6, app_size-next_size, NULL ); + } + return err; + + NOT_USED( tail ); +} + /*------------------------------------------------------------------------*/ _kernel_oserror *main_initialise (char *tail, int podule_base, void *workspace) @@ -679,6 +696,7 @@ _kernel_oserror *main_initialise (char *tail, int podule_base, Commands [main_LOAD_CMOS] = &Load_CMOS; Commands [main_REPEAT] = &Repeat; Commands [main_SAFE_LOGON] = &Safe_Logon; + Commands [main_FREE_POOL] = *Free_Pool; finish: if (error != NULL) diff --git a/h/main b/h/main index 1074d245f0caca4a3e73d6fbf2c77d18bff90a16..60da38d206ba40193bc523156c050afa5380616d 100644 --- a/h/main +++ b/h/main @@ -42,7 +42,8 @@ #define main_LOAD_CMOS 4 #define main_REPEAT 5 #define main_SAFE_LOGON 6 -#define main_COMMAND_COUNT 7 +#define main_FREE_POOL 7 +#define main_COMMAND_COUNT 8 extern _kernel_oserror *main_initialise (char *, int, void *);