Clean up amf_d.c