Use only spaces for indentation.
Removed malloc, and bad call to delete on a variable allocated with malloc.
Added file upload example.