From 229d21ef728110099798ab445436b7564da63ea1 Mon Sep 17 00:00:00 2001 From: Patrick Pelissier Date: Mon, 18 Feb 2019 15:46:53 +0100 Subject: [PATCH] Add assume --- m-string.h | 1 + 1 file changed, 1 insertion(+) diff --git a/m-string.h b/m-string.h index c4d1fcb4..3abb3919 100644 --- a/m-string.h +++ b/m-string.h @@ -214,6 +214,7 @@ stringi_fit2size (string_t v, size_t size_alloc) abort(); return; } + M_ASSUME(ptr != &v->u.stack.buffer[1]); if (string_int_stack_p(v)) { /* Copy the stack allocation into the heap allocation */ memcpy(ptr, &v->u.stack.buffer[1], v->u.stack.buffer[0]+1);