greybus: power_supply: fix leak getting string properties

When fetching string properties, memory was being allocated and leaked
when it was not necessary to do so.

Signed-off-by: Rui Miguel Silva <rui.silva@linaro.org>
Reviewed-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
1 file changed
tree: 726e26a1f65cf713838bd6f9b3e1b00f2d47ece2
  1. drivers/