Contrary to CBS_stow(), CBB_finish() will leak, so ensure we fail if
*out_data is populated.
Discussed with & ok jsing
-/* $OpenBSD: bs_cbb.c,v 1.27 2022/01/06 14:30:30 jsing Exp $ */
+/* $OpenBSD: bs_cbb.c,v 1.28 2022/07/07 17:12:15 tb Exp $ */
/*
* Copyright (c) 2014, Google Inc.
*
*/
return 0;
+ if (out_data != NULL && *out_data != NULL)
+ return 0;
+
if (out_data != NULL)
*out_data = cbb->base->buf;