not deallcating memory for char[] format and resizeStyle