[Search for users]
[Overall Top Noters]
[List of all Conferences]
[Download this site]
Title: | AMIGA NOTES |
Notice: | Join us in the *NEW* conference - HYDRA::AMIGA_V2 |
Moderator: | HYDRA::MOORE |
|
Created: | Sat Apr 26 1986 |
Last Modified: | Wed Feb 05 1992 |
Last Successful Update: | Fri Jun 06 1997 |
Number of topics: | 5378 |
Total number of notes: | 38326 |
520.0. "Patch Kits for MANX C V3.4a" by KIRK::LONG () Mon Jun 01 1987 12:33
Does anybody know if this is the latest PATCH.C for MANX C? I got this from
USENET and was interested in comments before I apply it.
Thanks,
Dick
------------------------------------------------------------------------------
/*
* Aztec C68K/Am PATCH program v 1.3 - 4/2/87
*
* This program provides patches which fix bugs in the 3.4a version
* of the Aztec C68K system.
*/
/*
* 1) A statement of the form: < array[index] op= > will sometimes generate
* incorrect code which will modify the wrong address in memory.
*
* 2) A multiplication/division/modulo operation involving CHAR types
* within a conditional statement generates incorrect code.
* (Patch fixed in v 1.2)
*
* 3) Some bit field operations used the "lsr" instruction instead of the
* "ror" instruction.
*
* 4) The abs() routine is incorrectly being detected by the 68881 code
* generation.
*
* 5) In AS, a null pointer is sometimes used.
*
* 6-9) Fix AddGList function in cXXX.lib.
*
* 10-13) Fix NewModifyProp function in cXXX.lib.
*
*/
short patch1[] = {0x2f2a, 0x0006, 0x2f07, 0x2f2a, 0x0006, 0x487a,
0x057f, 0x4eac, 0x8320, 0x422c, 0x9412, 0x2f2a,
0x0006, 0x4eac, 0x825a, 0x4fef, 0x0014};
short patch2[] = {0x246d, 0x0008, 0x3012, 0xc07c, 0x00ff, 0x43ec,
0x8d62, 0x0831, 0x0005, 0x0000, 0x6604, 0x4a45,
0x6758, 0x3f05, 0x2f2a, 0x0012, 0x6158, 0x3800,
0x2eaa, 0x000e, 0x6150, 0x5c4f, 0xc840, 0x6742,
0x3f05, 0x2f2a, 0x0012, 0x4eba, 0x0206, 0x5c4f,
0x2540, 0x0012, 0x3f05, 0x2f2a, 0x000e};
short patch3[] = {0x006c, 0x736c, 0x0072, 0x6f72};
short patch4[] = {0x5a7a, 0x5a00};
short patch5[] = {0x2008, 0x6730, 0x4a28, 0x000c, 0x662a, 0x302a,
0x0006, 0xc07c, 0x00cf, 0xb07c, 0x0040, 0x6608};
short patch6[] = {0x0008, 0x4cef, 0x0403, 0x0010};
short patch10[] = {0x0010, 0x4cef, 0x003f, 0x001c};
struct patches {
short size;
long offset;
short *patch;
char *program;
long check;
char *chkstr;
} patches[] = {
sizeof(patch1), 0xb564, patch1, "cc", 0x357f, "3.4a",
sizeof(patch2), 0xf2de, patch2, "cc", 0x357f, "3.4a",
sizeof(patch3), 0xe514, patch3, "cc", 0x357f, "3.4a",
sizeof(patch4), 0x10a78, patch4, "cc", 0x357f, "3.4a",
sizeof(patch5), 0x83a2, patch5, "as", 0x6202, "3.4a",
sizeof(patch6), 0xdf4e, patch6, "c.lib", 0xdf08, "jgaddglist",
sizeof(patch6), 0xe156, patch6, "c32.lib", 0xe110, "jgaddglist",
sizeof(patch6), 0xe2a4, patch6, "cl.lib", 0xe25c, "jgaddglist",
sizeof(patch6), 0xe66c, patch6, "cl32.lib", 0xe624, "jgaddglist",
sizeof(patch10), 0xf381, patch10, "c.lib", 0xf334, "jgnewmodif",
sizeof(patch10), 0xf589, patch10, "c32.lib", 0xf53c, "jgnewmodif",
sizeof(patch10), 0xf6f3, patch10, "cl.lib", 0xf6a4, "jgnewmodif",
sizeof(patch10), 0xfabb, patch10, "cl32.lib", 0xfa6c, "jgnewmodif",
0
};
main()
{
int fd;
struct patches *pp;
char buf[80];
for (pp=patches;pp->size;pp++) {
printf("Applying patch %d ", pp-patches+1);
if ((fd = open(pp->program, 2)) < 0) {
printf("\nError opening program file <%s>, skipping ...\n",
pp->program);
continue;
}
printf("to <%s>\n", pp->program);
lseek(fd, pp->check, 0);
read(fd, buf, strlen(pp->chkstr));
buf[strlen(pp->chkstr)] = 0;
if (strcmp(buf, pp->chkstr)) {
printf("Error: program is not the correct version,"
"skipping ...\n");
close(fd);
continue;
}
lseek(fd, pp->offset, 0);
write(fd, pp->patch, pp->size);
close(fd);
}
}
T.R | Title | User | Personal Name | Date | Lines |
---|
520.1 | | COOKIE::WECKER | Dave (Cum Grano Salis) Wecker | Mon Jun 01 1987 18:20 | 5 |
| re: .0
I've used it. It works fine and as far as I know is the most up to date
available.
|