Language: Python
Label: safe
CWE: CWE-415 \u2014 Double Free
The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations.

Code:
  def testPoolingIllegalRatioForBatch(self):
    with self.cached_session() as _:
      with self.assertRaises(errors.UnimplementedError):
        result = nn_ops.gen_nn_ops.fractional_avg_pool(
            np.zeros([3, 30, 50, 3]),
            [2, 3, 1.5, 1],
            True,
            True)
        self.evaluate(result)