Save foo return value, then delete[] it

Valgrind output:

    $ valgrind --tool=memcheck --leak-check=yes --track-origins=yes ./Data.out

    ==12297== Memcheck, a memory error detector
    ==12297== Copyright (C) 2002-2013, and GNU GPL'd, by Julian Seward et al.
    ==12297== Using Valgrind-3.9.0 and LibVEX; rerun with -h for copyright info
    ==12297== Command: ./Data.out
    ==12297==
    ==12297== Warning: client switching stacks?  SP change: 0xbef3b6c0 --> 0x4022f9c
    ==12297==          to suppress, use: --max-stackframe=1158576348 or greater
    ==12297== Warning: client switching stacks?  SP change: 0x4022f9c --> 0xbef3b6c0
    ==12297==          to suppress, use: --max-stackframe=1158576348 or greater
    ==12297==
    ==12297== HEAP SUMMARY:
    ==12297==     in use at exit: 0 bytes in 0 blocks
    ==12297==   total heap usage: 1 allocs, 1 frees, 20 bytes allocated
    ==12297==
    ==12297== All heap blocks were freed -- no leaks are possible
    ==12297==
    ==12297== For counts of detected and suppressed errors, rerun with: -v
    ==12297== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)