eamad: fix excessive memory allocation. Fixes Ticket792 Bug found by Oana Stratulat
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>