Fix accidental free of non-allocated memory

Currently retrieving a value that doesn't exist can result in a
free of d_string, which isn't actually allocated. This commit
ensures that we got a value from buxton before attempting
to free a string (if the type was indeed STRING)

Signed-off-by: Michael Ikey Doherty <michael.i.doherty@intel.com>