From 2afece36f6006844e87d7cb2fcb1ad8b220b2623 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Wed, 16 May 2018 17:00:35 +0200 Subject: support: Add TEST_COMPARE_BLOB, support_quote_blob The declaration of support_test_compare_blob uses unsigned long int, to avoid including . Reviewed-by: Carlos O'Donell --- support/support.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'support/support.h') diff --git a/support/support.h b/support/support.h index bc5827e..b61fe07 100644 --- a/support/support.h +++ b/support/support.h @@ -59,6 +59,12 @@ void support_shared_free (void *); process on error. */ void support_write_file_string (const char *path, const char *contents); +/* Quote the contents of the byte array starting at BLOB, of LENGTH + bytes, in such a way that the result string can be included in a C + literal (in single/double quotes, without putting the quotes into + the result). */ +char *support_quote_blob (const void *blob, size_t length); + /* Error-checking wrapper functions which terminate the process on error. */ -- cgit v1.1