Fix memory leak in median
Fix memory leak in median

hshindo/arrayfire,arrayfire/arrayfire,bkloppenborg/arrayfire,arrayfire/arrayfire,shehzan10/arrayfire,marbre/arrayfire,marbre/arrayfire,victorv/arrayfire,bkloppenborg/arrayfire,9prady9/arrayfire,hshindo/arrayfire,umar456/arrayfire,marbre/arrayfire,pentschev/arrayfire,pentschev/arrayfire,marbre/arrayfire,hshindo/arrayfire,merlin-ext/arrayfire,munnybearz/arrayfire,victorv/arrayfire,pentschev/arrayfire,shehzan10/arrayfire,shehzan10/arrayfire,shehzan10/arrayfire,munnybearz/arrayfire,pentschev/arrayfire,ghisvail/arrayfire,ghisvail/arrayfire,merlin-ext/arrayfire,munnybearz/arrayfire,merlin-ext/arrayfire,victorv/arrayfire,arrayfire/arrayfire,9prady9/arrayfire,victorv/arrayfire,umar456/arrayfire,hshindo/arrayfire,merlin-ext/arrayfire,ghisvail/arrayfire,umar456/arrayfire,arrayfire/arrayfire,9prady9/arrayfire,ghisvail/arrayfire,bkloppenborg/arrayfire,umar456/arrayfire,9prady9/arrayfire,bkloppenborg/arrayfire