checking before release core foundation objects