Fixing minor exception checks

	- uta_ring_free() updated to free resources
	- Exception Handling to avoid reference null_ptr
	- free_ctx() updated to free resources
	- err: added to safely handle resource free

Issue-ID: RIC-673

Signed-off-by: swc <sw94.chung@samsung.com>
Change-Id: I2645d6eddb230ca9cf2822c778c1b533e5da1f9b
4 files changed