Add warn_unused_result attribute to ecma_string_to_utf8_string. Add assertions that specified buffer size is sufficient in places, where return value of ecma_string_to_utf8_string wasn't checked prior to the changes.

JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
This commit is contained in:
Ruben Ayrapetyan
2015-08-27 17:12:26 +03:00
parent 6ee561e821
commit a26c454219
12 changed files with 99 additions and 52 deletions
+1
View File
@@ -29,6 +29,7 @@
#define __noreturn __attribute__((noreturn))
#define __attr_noinline___ __attribute__((noinline))
#define __attr_used___ __attribute__((used))
#define __attr_return_value_should_be_checked___ __attribute__((warn_unused_result))
#ifndef __attr_always_inline___
# define __attr_always_inline___ __attribute__((always_inline))
#endif /* !__attr_always_inline___ */