diff options
author | Josh Allen <axlecrusher@gmail.com> | 2017-02-12 14:34:29 -0500 |
---|---|---|
committer | Josh Allen <axlecrusher@gmail.com> | 2017-02-12 14:34:29 -0500 |
commit | c2ca44be9f6408351cfe32e855b1472ec155b9b2 (patch) | |
tree | eab2e997efb2d425c07e6782128f941b3f103313 /tools/ootx_decode/ootx_decoder.c | |
parent | 6ad28759408695a4825738bcc32bc294d1869ca8 (diff) | |
download | libsurvive-c2ca44be9f6408351cfe32e855b1472ec155b9b2.tar.gz libsurvive-c2ca44be9f6408351cfe32e855b1472ec155b9b2.tar.bz2 |
free decoder context
Diffstat (limited to 'tools/ootx_decode/ootx_decoder.c')
-rw-r--r-- | tools/ootx_decode/ootx_decoder.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/ootx_decode/ootx_decoder.c b/tools/ootx_decode/ootx_decoder.c index dc5d50a..f308bfb 100644 --- a/tools/ootx_decode/ootx_decoder.c +++ b/tools/ootx_decode/ootx_decoder.c @@ -33,6 +33,12 @@ void ootx_init_decoder_context(ootx_decoder_context *ctx) { *(ctx->payload_size) = 0; } +void ootx_free_decoder_context(ootx_decoder_context *ctx) { + free(ctx->buffer); + ctx->buffer = NULL; + ctx->payload_size = NULL; +} + /* how to decode pulses ticks>2000 && delta>100000== master lighthouse |