Project

General

Profile

Actions

Bug #3410

closed

Viterbi decoder reads uninitialized memory

Added by jenda almost 6 years ago. Updated almost 6 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
-
Target version:
-
Start date:
07/21/2018
Due date:
% Done:

100%

Resolution:
Spec Reference:
Tags:

Description

Running tetra-rx on a capture with lots of bit errors is not deterministic. Investigation with Valgrind shows various errors about uninitialised values in libosmocore's viterbi decoder.

The cause appears to lie in lower_mac/viterbi.c. The only function there allocates space for 864 symbols and then fills it with the symbols received. However, sym_count is sometimes less than 864, leaving the rest of the array uninitialized.

Initializing it with int8_t vit_inp[864*4] = {0}; fixes the problem.

Actions

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 48.8 MB)