Skip to content

Commit fd60ca8

Browse files
committed
fix some build warnings [-WFormat]
1 parent 0d68145 commit fd60ca8

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

ext/php_driver.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ throw_invalid_argument(zval *object,
325325
if (cls_name) {
326326
zend_throw_exception_ex(php_driver_invalid_argument_exception_ce, 0 TSRMLS_CC,
327327
"%s must be %s, an instance of %.*s given",
328-
object_name, expected_type, cls_len, cls_name);
328+
object_name, expected_type, (int)cls_len, cls_name);
329329
#if PHP_MAJOR_VERSION >= 7
330330
zend_string_release(str);
331331
#else
@@ -367,7 +367,11 @@ PHP_INI_MH(OnUpdateLogLevel)
367367
} else {
368368
php_error_docref(NULL TSRMLS_CC, E_NOTICE,
369369
PHP_DRIVER_NAME " | Unknown log level '%s', using 'ERROR'",
370+
#if PHP_MAJOR_VERSION >= 7
371+
ZSTR_VAL(new_value));
372+
#else
370373
new_value);
374+
#endif
371375
cass_log_set_level(CASS_LOG_ERROR);
372376
}
373377
}

0 commit comments

Comments
 (0)