MIRROR: javascript for ๐Ÿœ's, a tiny runtime with big ambitions
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

add format attribute to js_create_error function

+1 -3
+1 -3
src/ant.c
··· 2474 2474 return (js_err_type_t)(int)js_getnum(err_type); 2475 2475 } 2476 2476 2477 + __attribute__((format(printf, 4, 5))) 2477 2478 jsval_t js_create_error(struct js *js, js_err_type_t err_type, jsval_t props, const char *xx, ...) { 2478 2479 va_list ap; 2479 2480 int line = 0, col = 0; ··· 2494 2495 get_error_line(js->code, js->clen, js->toff > 0 ? js->toff : js->pos, error_line, sizeof(error_line), &error_col); 2495 2496 2496 2497 va_start(ap, xx); 2497 - #pragma GCC diagnostic push 2498 - #pragma GCC diagnostic ignored "-Wformat-nonliteral" 2499 2498 vsnprintf(error_msg, sizeof(error_msg), xx, ap); 2500 - #pragma GCC diagnostic pop 2501 2499 va_end(ap); 2502 2500 2503 2501 const char *err_name = get_error_type_name(err_type);