summaryrefslogtreecommitdiff
path: root/PE/rebuildmenus.cpp
diff options
context:
space:
mode:
authorpixel <pixel>2003-12-28 13:07:52 +0000
committerpixel <pixel>2003-12-28 13:07:52 +0000
commit24ae6e6865351db7d3a9e58340e5a2684912544f (patch)
tree1236f54aaed224b650689cf5f2190557860f1952 /PE/rebuildmenus.cpp
parent3d7a6fcba7ae7190585569e17e970cd5138ec9e4 (diff)
Fixing patch.
Diffstat (limited to 'PE/rebuildmenus.cpp')
-rw-r--r--PE/rebuildmenus.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/PE/rebuildmenus.cpp b/PE/rebuildmenus.cpp
index 76b3e97..681e909 100644
--- a/PE/rebuildmenus.cpp
+++ b/PE/rebuildmenus.cpp
@@ -4,7 +4,7 @@
CODE_BEGINS
virtual int startup(void) throw (GeneralException) {
- int i, p;
+ int i, j, p, s;
Handle * inter = new Output("concat.out");
Handle * f, * out;
String fname;
@@ -18,6 +18,7 @@ virtual int startup(void) throw (GeneralException) {
for (i = 0; i < 4; i++) {
fname = "menus" + String(i) + ".out";
f = new Input(fname);
+ s = f->GetSize();
p = inter->tell();
@@ -27,6 +28,14 @@ virtual int startup(void) throw (GeneralException) {
copy(f, inter);
+ s &= 3;
+
+ if (s) {
+ s = 4 - s;
+ for (j = 0; j < s; j++)
+ inter->writeU8(0);
+ }
+
delete f;
}