Commit db10718b authored by Vish (Ishaya) Abrams's avatar Vish (Ishaya) Abrams Committed by gunan
Browse files

Handle nil return from TF_TensorData (#14082)

With some memory allocators, attempting to allocate 0 bytes will return
a null pointer. This specifically happens when building tensorflow with
mkl support. If TF_TensorData returns null, the go code to create a
slice from the data leads to a null pointer exception. This fixes the
issue by checking for the nil return and returning a slice zero value to
(nil) to the caller. Fixes #13764.
parent 8245e79e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment