aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOzkan Sezer <sezeroz@gmail.com>2020-10-05 00:41:40 +0300
committerCyrill Gorcunov <gorcunov@gmail.com>2020-10-10 00:13:07 +0300
commit723fb2cc3309b9963620e8b54f3709e7a3331c57 (patch)
tree5ef4afd15bf00db20897461f5a557fd34a4a5e26
parentc2ea414eb343c6335a225021730c2f29a17a01d4 (diff)
downloadnasm-723fb2cc3309b9963620e8b54f3709e7a3331c57.tar.gz
nasm-723fb2cc3309b9963620e8b54f3709e7a3331c57.tar.xz
nasm-723fb2cc3309b9963620e8b54f3709e7a3331c57.zip
rdoff/rdfwriteheader: Write object length and header length in correct order
Compared to 2.12.xx rdfwriteheader() writes the object length and header length in flipped order. Issue seems to have been introduced by commit 8dc965347ddf. BR3392717 Signed-off-by: Ozkan Sezer <sezeroz@gmail.com> Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
-rw-r--r--rdoff/rdoff.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/rdoff/rdoff.c b/rdoff/rdoff.c
index 77f2b42f..3057f84f 100644
--- a/rdoff/rdoff.c
+++ b/rdoff/rdoff.c
@@ -612,8 +612,8 @@ int rdfwriteheader(FILE * fp, rdf_headerbuf * h)
l = membuflength(h->buf);
l2 = l + 14 + 10 * h->nsegments + h->seglength;
- fwriteint32_t(l, fp);
- fwriteint32_t(l2, fp);
+ fwriteint32_t(l2, fp); /* object length */
+ fwriteint32_t(l, fp); /* header length */
membufdump(h->buf, fp);