summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--ext/fiddle/lib/fiddle/cparser.rb2
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index afba089..7ba7c96 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sat Jan 3 18:53:28 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * ext/fiddle/lib/fiddle/cparser.rb (parse_ctype): limit split word
+ number as the rest are not used.
+
Sat Jan 3 18:19:50 2015 SHIBATA Hiroshi <shibata.hiroshi@gmail.com>
* ext/fiddle/lib/fiddle/cparser.rb: r49110 broke Fiddle::Import with
diff --git a/ext/fiddle/lib/fiddle/cparser.rb b/ext/fiddle/lib/fiddle/cparser.rb
index 39812e1..4be82a6 100644
--- a/ext/fiddle/lib/fiddle/cparser.rb
+++ b/ext/fiddle/lib/fiddle/cparser.rb
@@ -169,7 +169,7 @@ module Fiddle
when /\*/, /\[[\s\d]*\]/
return TYPE_VOIDP
else
- ty = ty.split(' ')[0]
+ ty = ty.split(' ', 2)[0]
if( tymap[ty] )
return parse_ctype(tymap[ty], tymap)
else