sanm: convert to refcounted frames

Signed-off-by: Paul B Mahol <onemda@gmail.com>