diff options
author | Ben Smith <binji@chromium.org> | 2016-04-25 07:11:01 -0700 |
---|---|---|
committer | Ben Smith <binji@chromium.org> | 2016-04-28 23:45:51 -0700 |
commit | 8ff085d37bb107cabe7e9305553f7c3179e4ded8 (patch) | |
tree | 2e8f8f1ec78689fb1594ca509a3bd0fb75c205e0 /src/wasm-binary-writer.c | |
parent | 8b8647dc8f4cc032d5ce932fd4df22ff3714086d (diff) | |
download | wabt-8ff085d37bb107cabe7e9305553f7c3179e4ded8.tar.gz wabt-8ff085d37bb107cabe7e9305553f7c3179e4ded8.tar.bz2 wabt-8ff085d37bb107cabe7e9305553f7c3179e4ded8.zip |
move section length after section name
Diffstat (limited to 'src/wasm-binary-writer.c')
-rw-r--r-- | src/wasm-binary-writer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/wasm-binary-writer.c b/src/wasm-binary-writer.c index 4a33a8a7..c2fbea89 100644 --- a/src/wasm-binary-writer.c +++ b/src/wasm-binary-writer.c @@ -250,11 +250,11 @@ static void begin_section(WasmContext* ctx, char desc[100]; wasm_snprintf(desc, sizeof(desc), "section \"%s\"", name); write_header(ctx, desc, PRINT_HEADER_NO_INDEX); - ctx->last_section_offset = - write_u32_leb128_space(ctx, leb_size_guess, "section size (guess)"); ctx->last_section_leb_size_guess = leb_size_guess; wasm_snprintf(desc, sizeof(desc), "section id: \"%s\"", name); write_str(&ctx->stream, name, strlen(name), WASM_DONT_PRINT_CHARS, desc); + ctx->last_section_offset = + write_u32_leb128_space(ctx, leb_size_guess, "section size (guess)"); } static void end_section(WasmContext* ctx) { |