X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=assembler%2Fmain.c;h=ad180b274bc8ac2520718a83f7590d5a3b23011b;hb=1a43ed005f3ffe10b0ca3d6f2975870c8d505b92;hp=5981a42bc5b8a998f34c5aa5b62d4a497aab1eaf;hpb=b756ecc447336244a0340daaa821a12c2b8f7c61;p=b43-tools.git diff --git a/assembler/main.c b/assembler/main.c index 5981a42..ad180b2 100644 --- a/assembler/main.c +++ b/assembler/main.c @@ -429,7 +429,7 @@ static struct code_output * do_assemble_insn(struct assembler_context *ctx, struct instruction *insn, unsigned int opcode) { - int i; + unsigned int i; struct operlist *ol; int nr_oper = 0; uint64_t code = 0; @@ -1017,7 +1017,7 @@ static void resolve_labels(struct assembler_context *ctx) { struct code_output *c; int addr; - int i; + unsigned int i; unsigned int current_address; /* Calculate the absolute addresses for each instruction. */ @@ -1104,7 +1104,7 @@ static void emit_code(struct assembler_context *ctx) exit(1); } if (IS_VERBOSE_DEBUG) - fprintf(stderr, "\nCode:\n"); + printf("\nCode:\n"); list_for_each_entry(c, &ctx->output, list) { switch (c->type) { @@ -1152,7 +1152,7 @@ static void emit_code(struct assembler_context *ctx) switch (c->type) { case OUT_INSN: if (IS_VERBOSE_DEBUG) { - fprintf(stderr, "%03X %03X,%03X,%03X\n", + printf("%03X %04X,%04X,%04X\n", c->opcode, c->operands[0].u.operand, c->operands[1].u.operand,