diff options
author | Jim Blandy <jimb@redhat.com> | 1992-01-13 21:48:03 +0000 |
---|---|---|
committer | Jim Blandy <jimb@redhat.com> | 1992-01-13 21:48:03 +0000 |
commit | 254f294c2e37a22e04bff74fedfdc9b1fcc93b93 (patch) | |
tree | 060dbe9a444bcf1c2e1bc7802fc4dfc1717520aa /src/unexhp9k800.c | |
parent | a48a36d045feed054f3532c5596449466a60a3cd (diff) | |
download | emacs-254f294c2e37a22e04bff74fedfdc9b1fcc93b93.tar.gz |
entered into RCS
Diffstat (limited to 'src/unexhp9k800.c')
-rw-r--r-- | src/unexhp9k800.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/unexhp9k800.c b/src/unexhp9k800.c index 259b9318514..8d34a3a3d7a 100644 --- a/src/unexhp9k800.c +++ b/src/unexhp9k800.c @@ -60,6 +60,7 @@ unexec(new_name, old_name, new_end_of_text, dummy1, dummy2) int old_size, new_size; struct header hdr; struct som_exec_auxhdr auxhdr; + long i; /* For the greatest flexibility, should create a temporary file in the same directory as the new file. When everything is complete, @@ -81,7 +82,10 @@ unexec(new_name, old_name, new_end_of_text, dummy1, dummy2) /* Decide how large the new and old data areas are */ old_size = auxhdr.exec_dsize; - new_size = sbrk(0) - auxhdr.exec_dmem; + /* I suspect these two statements are separate + to avoid a compiler bug in hpux version 8. */ + i = sbrk (0); + new_size = i - auxhdr.exec_dmem; /* Copy the old file to the new, up to the data space */ lseek(old, 0, 0); |