defrag: removed unused functions