ffi 1.9.12-x86-mingw32 → 1.9.13-x86-mingw32

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of ffi might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0e7f26deb92dfb11bacb683e61522e28f4c7185f
4
- data.tar.gz: afe0a0b8762cce3f055d77763646b752fc923322
3
+ metadata.gz: 3a99f7cc0ee695104250f882d7cdbda9f0a96a99
4
+ data.tar.gz: 31bd2d4062179eecfbb2d0fe5cc8caa4f0a1ecd4
5
5
  SHA512:
6
- metadata.gz: 079e3e16efd86c759e8fabe903535a811beea2925283aca24189d9b26c86a99bfef161078f4c4d7116df2326ea24301d20ecf776972efb021921d21b52547dc2
7
- data.tar.gz: 6ef1828d0a3bd1d29e985dce9a0116ffe6936cb96c630178d70bffd088b1dbbd3b307470eb455512e3b19360e10555dd2dc6692e54b5d0fe12ff9d08dedb3d3b
6
+ metadata.gz: 21a921e2ddf9360182541d2a450443bb5e5ead2ac6ffe1f13f034f2f8ae0c1e4ca088b1eb14a9e59bb8525fc1302d2245c303b62064e95a9d4a148c59fe1e364
7
+ data.tar.gz: a5289e8ec9928212214cbd7e29eb33229e555ad8ada55169539940e70cd6cfc7d99b4fefa8843ae2a3eea85ec02815692f45dd25ca518860bb71eac3db33e94b
data/lib/1.8/ffi_c.so CHANGED
Binary file
data/lib/1.9/ffi_c.so CHANGED
Binary file
data/lib/2.0/ffi_c.so CHANGED
Binary file
data/lib/2.1/ffi_c.so CHANGED
Binary file
data/lib/2.2/ffi_c.so CHANGED
Binary file
data/lib/ffi/library.rb CHANGED
@@ -122,20 +122,21 @@ module FFI
122
122
  end
123
123
  end
124
124
 
125
- # TODO better library lookup logic
126
- unless libname.to_s.start_with?("/")
127
- path = ['/usr/lib/','/usr/local/lib/'].find do |pth|
128
- File.exist?(pth + libname)
129
- end
130
- if path
131
- libname = path + libname
132
- retry
133
- end
134
- end
135
-
136
125
  if ldscript
137
126
  retry
138
127
  else
128
+ # TODO better library lookup logic
129
+ libname = libname.to_s
130
+ unless libname.start_with?("/")
131
+ path = ['/usr/lib/','/usr/local/lib/'].find do |pth|
132
+ File.exist?(pth + libname)
133
+ end
134
+ if path
135
+ libname = path + libname
136
+ retry
137
+ end
138
+ end
139
+
139
140
  libr = (orig == libname ? orig : "#{orig} #{libname}")
140
141
  errors[libr] = ex
141
142
  end
data/lib/ffi/version.rb CHANGED
@@ -1,4 +1,4 @@
1
1
  module FFI
2
- VERSION = '1.9.12'
2
+ VERSION = '1.9.13'
3
3
  end
4
4
 
@@ -96,6 +96,16 @@ describe "Library" do
96
96
  }.not_to raise_error
97
97
  end
98
98
 
99
+ it "loads library using symbol" do
100
+ expect {
101
+ expect(Module.new do |m|
102
+ m.extend FFI::Library
103
+ ffi_lib :c
104
+ attach_function :getpid, [ ], :uint
105
+ end.getpid).to eq(Process.pid)
106
+ }.not_to raise_error
107
+ end
108
+
99
109
  it "attach_function :getpid from [ 'c', 'libc.so.6'] " do
100
110
  expect {
101
111
  expect(Module.new do |m|
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ffi
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.12
4
+ version: 1.9.13
5
5
  platform: x86-mingw32
6
6
  authors:
7
7
  - Wayne Meissner