From 3290735c8f06bae617d0aba6ce645a554a7afc32 Mon Sep 17 00:00:00 2001 From: Connor Olding Date: Sun, 10 Apr 2016 08:56:00 -0700 Subject: [PATCH] pass numbers to writer instead of hex strings --- lips/Dumper.lua | 3 +-- lips/init.lua | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/lips/Dumper.lua b/lips/Dumper.lua index 1792b41..c02345e 100644 --- a/lips/Dumper.lua +++ b/lips/Dumper.lua @@ -233,8 +233,7 @@ end function Dumper:write(t) for _, b in ipairs(t) do - local s = ('%02X'):format(b) - self.writer(self.pos, s) + self.writer(self.pos, b) self.pos = self.pos + 1 end end diff --git a/lips/init.lua b/lips/init.lua index 76768bb..74bc83b 100644 --- a/lips/init.lua +++ b/lips/init.lua @@ -18,7 +18,7 @@ function lips.word_writer() local max = -1 return function(pos, b) if pos then - buff[pos] = b + buff[pos] = ("%02X"):format(b) if pos > max then max = pos end