Hello community, here is the log from the commit of package rubygem-ffi for openSUSE:Factory checked in at 2019-11-28 10:17:47 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/rubygem-ffi (Old) and /work/SRC/openSUSE:Factory/.rubygem-ffi.new.26869 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "rubygem-ffi" Thu Nov 28 10:17:47 2019 rev:32 rq:751494 version:1.11.3 Changes: -------- --- /work/SRC/openSUSE:Factory/rubygem-ffi/rubygem-ffi.changes 2019-11-13 13:26:44.575598607 +0100 +++ /work/SRC/openSUSE:Factory/.rubygem-ffi.new.26869/rubygem-ffi.changes 2019-11-28 10:18:02.079639546 +0100 @@ -1,0 +2,7 @@ +Thu Nov 28 07:21:16 UTC 2019 - Manuel Schnitzer <mschnit...@suse.com> + +- updated to version 1.11.3 + + * Remove support for tainted objects which cause deprecation warnings in ruby-2.7. #730 + +------------------------------------------------------------------- Old: ---- ffi-1.11.2.gem New: ---- ffi-1.11.3.gem ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ rubygem-ffi.spec ++++++ --- /var/tmp/diff_new_pack.UGpHzC/_old 2019-11-28 10:18:02.783639554 +0100 +++ /var/tmp/diff_new_pack.UGpHzC/_new 2019-11-28 10:18:02.787639554 +0100 @@ -24,7 +24,7 @@ # Name: rubygem-ffi -Version: 1.11.2 +Version: 1.11.3 Release: 0 %define mod_name ffi %define mod_full_name %{mod_name}-%{version} ++++++ ffi-1.11.2.gem -> ffi-1.11.3.gem ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/CHANGELOG.md new/CHANGELOG.md --- old/CHANGELOG.md 2019-11-11 21:47:21.000000000 +0100 +++ new/CHANGELOG.md 2019-11-25 15:16:43.000000000 +0100 @@ -1,3 +1,10 @@ +1.11.3 / 2019-11-25 +------------------- + +Removed: +* Remove support for tainted objects which cause deprecation warnings in ruby-2.7. #730 + + 1.11.2 / 2019-11-11 ------------------- Binary files old/checksums.yaml.gz and new/checksums.yaml.gz differ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ext/ffi_c/AbstractMemory.c new/ext/ffi_c/AbstractMemory.c --- old/ext/ffi_c/AbstractMemory.c 2019-11-11 21:47:21.000000000 +0100 +++ new/ext/ffi_c/AbstractMemory.c 2019-11-25 15:16:43.000000000 +0100 @@ -417,7 +417,7 @@ checkBounds(ptr, off, len); end = memchr(ptr->address + off, 0, len); - return rb_tainted_str_new((char *) ptr->address + off, + return rb_str_new((char *) ptr->address + off, (end != NULL ? end - ptr->address - off : len)); } @@ -453,7 +453,7 @@ for (i = 0; i < count; ++i) { const char* strptr = *((const char**) (ptr->address + off) + i); - rb_ary_push(retVal, (strptr == NULL ? Qnil : rb_tainted_str_new2(strptr))); + rb_ary_push(retVal, (strptr == NULL ? Qnil : rb_str_new2(strptr))); } } else { @@ -463,7 +463,7 @@ if (strptr == NULL) { break; } - rb_ary_push(retVal, rb_tainted_str_new2(strptr)); + rb_ary_push(retVal, rb_str_new2(strptr)); } } @@ -542,7 +542,7 @@ checkRead(ptr); checkBounds(ptr, off, len); - return rb_tainted_str_new((char *) ptr->address + off, len); + return rb_str_new((char *) ptr->address + off, len); } /* @@ -583,10 +583,6 @@ checkWrite(ptr); checkBounds(ptr, off, len); - if (rb_safe_level() >= 1 && OBJ_TAINTED(str)) { - rb_raise(rb_eSecurityError, "Writing unsafe string to memory"); - return Qnil; - } memcpy(ptr->address + off, RSTRING_PTR(str) + idx, len); return self; @@ -718,7 +714,7 @@ memcpy(&tmp, ptr->address + offset, sizeof(tmp)); } - return tmp != NULL ? rb_tainted_str_new2(tmp) : Qnil; + return tmp != NULL ? rb_str_new2(tmp) : Qnil; } static void diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ext/ffi_c/Call.c new/ext/ffi_c/Call.c --- old/ext/ffi_c/Call.c 2019-11-11 21:47:21.000000000 +0100 +++ new/ext/ffi_c/Call.c 2019-11-25 15:16:43.000000000 +0100 @@ -298,10 +298,6 @@ param->ptr = NULL; } else { - if (rb_safe_level() >= 1 && OBJ_TAINTED(argv[argidx])) { - rb_raise(rb_eSecurityError, "Unsafe string parameter"); - } - param->ptr = StringValueCStr(argv[argidx]); } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ext/ffi_c/DynamicLibrary.c new/ext/ffi_c/DynamicLibrary.c --- old/ext/ffi_c/DynamicLibrary.c 2019-11-11 21:47:21.000000000 +0100 +++ new/ext/ffi_c/DynamicLibrary.c 2019-11-25 15:16:43.000000000 +0100 @@ -164,7 +164,7 @@ { char errmsg[1024]; dl_error(errmsg, sizeof(errmsg)); - return rb_tainted_str_new2(errmsg); + return rb_str_new2(errmsg); } static void diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ext/ffi_c/Function.c new/ext/ffi_c/Function.c --- old/ext/ffi_c/Function.c 2019-11-11 21:47:21.000000000 +0100 +++ new/ext/ffi_c/Function.c 2019-11-25 15:16:43.000000000 +0100 @@ -724,7 +724,7 @@ param = rbffi_longdouble_new(*(long double *) parameters[i]); break; case NATIVE_STRING: - param = (*(void **) parameters[i] != NULL) ? rb_tainted_str_new2(*(char **) parameters[i]) : Qnil; + param = (*(void **) parameters[i] != NULL) ? rb_str_new2(*(char **) parameters[i]) : Qnil; break; case NATIVE_POINTER: param = rbffi_Pointer_NewInstance(*(void **) parameters[i]); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ext/ffi_c/Types.c new/ext/ffi_c/Types.c --- old/ext/ffi_c/Types.c 2019-11-11 21:47:21.000000000 +0100 +++ new/ext/ffi_c/Types.c 2019-11-25 15:16:43.000000000 +0100 @@ -80,7 +80,7 @@ return rbffi_longdouble_new(*(long double *) ptr); case NATIVE_STRING: - return (*(void **) ptr != NULL) ? rb_tainted_str_new2(*(char **) ptr) : Qnil; + return (*(void **) ptr != NULL) ? rb_str_new2(*(char **) ptr) : Qnil; case NATIVE_POINTER: return rbffi_Pointer_NewInstance(*(void **) ptr); case NATIVE_BOOL: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/lib/ffi/version.rb new/lib/ffi/version.rb --- old/lib/ffi/version.rb 2019-11-11 21:47:21.000000000 +0100 +++ new/lib/ffi/version.rb 2019-11-25 15:17:03.000000000 +0100 @@ -1,3 +1,3 @@ module FFI - VERSION = '1.11.2' + VERSION = '1.11.3' end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/metadata new/metadata --- old/metadata 2019-11-11 21:47:21.000000000 +0100 +++ new/metadata 2019-11-25 15:16:42.000000000 +0100 @@ -1,14 +1,14 @@ --- !ruby/object:Gem::Specification name: ffi version: !ruby/object:Gem::Version - version: 1.11.2 + version: 1.11.3 platform: ruby authors: - Wayne Meissner autorequire: bindir: bin cert_chain: [] -date: 2019-11-11 00:00:00.000000000 Z +date: 2019-11-25 00:00:00.000000000 Z dependencies: - !ruby/object:Gem::Dependency name: rake