diff options
Diffstat (limited to 'Lib/ruby/rubycontainer.swg')
-rw-r--r-- | Lib/ruby/rubycontainer.swg | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/ruby/rubycontainer.swg b/Lib/ruby/rubycontainer.swg index 597ae83d2..ab2eeae83 100644 --- a/Lib/ruby/rubycontainer.swg +++ b/Lib/ruby/rubycontainer.swg @@ -186,7 +186,7 @@ namespace swig return swig::as<T>(item); } catch (const std::invalid_argument& e) { char msg[1024]; - sprintf(msg, "in sequence element %d ", _index); + SWIG_snprintf(msg, sizeof(msg), "in sequence element %d ", _index); VALUE lastErr = rb_gv_get("$!"); if ( lastErr == Qnil ) { %type_error(swig::type_name<T>()); |