iconv 1.0.3 → 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/ext/iconv/extconf.rb +1 -0
- data/ext/iconv/iconv.c +11 -8
- data/lib/iconv/version.rb +1 -1
- metadata +8 -15
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 3823e1fa1002a6e18053509f22feb19cd06d26e0
|
4
|
+
data.tar.gz: 9be3b153697065b641029e19b5eb83fb6a27bc86
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 013c937ab111480b165273d84ab8711e3c6fc2732c2ce8dd97179e7d467e942ad6a86305df6c759ed0dd04af2dc532660d10c310f97159510475d97f0e084cae
|
7
|
+
data.tar.gz: 14ca42d65ab95969bf7103e2902610c3b2bb639b0168b1e58aaf48a0b84bbff1e844068c67111ddf619684c716b0051f85ed9a9169ef500ed41ecb0685ecac6e
|
data/ext/iconv/extconf.rb
CHANGED
@@ -8,6 +8,7 @@ conf = with_config("config-charset", enable_config("config-charset", conf))
|
|
8
8
|
unless have_func("rb_enc_get", "ruby/encoding.h") || have_func("vasprintf", "stdio.h")
|
9
9
|
raise "vasprintf is required for Ruby 1.8"
|
10
10
|
end
|
11
|
+
have_func("rb_sys_fail_str", "ruby.h")
|
11
12
|
if have_func("iconv", "iconv.h") or
|
12
13
|
have_library("iconv", "iconv", "iconv.h")
|
13
14
|
check_signedness("size_t") rescue nil
|
data/ext/iconv/iconv.c
CHANGED
@@ -27,12 +27,6 @@
|
|
27
27
|
# define rb_f_notimplement rb_notimplement
|
28
28
|
# define rb_str_subseq(a, b, c) rb_str_substr(a, b, c)
|
29
29
|
# define rb_str_new_cstr(a) rb_str_new2(a)
|
30
|
-
NORETURN(static void rb_sys_fail_str(VALUE msg));
|
31
|
-
static void
|
32
|
-
rb_sys_fail_str(VALUE msg)
|
33
|
-
{
|
34
|
-
rb_sys_fail(RSTRING_PTR(msg));
|
35
|
-
}
|
36
30
|
static VALUE
|
37
31
|
rb_str_equal(str1, str2)
|
38
32
|
VALUE str1, str2;
|
@@ -72,6 +66,14 @@ rb_sprintf(const char *format, ...)
|
|
72
66
|
return rb_str_new(ret, len);
|
73
67
|
}
|
74
68
|
#endif
|
69
|
+
#ifndef HAVE_RB_SYS_FAIL_STR
|
70
|
+
NORETURN(static void rb_sys_fail_str(VALUE msg));
|
71
|
+
static void
|
72
|
+
rb_sys_fail_str(VALUE msg)
|
73
|
+
{
|
74
|
+
rb_sys_fail(RSTRING_PTR(msg));
|
75
|
+
}
|
76
|
+
#endif
|
75
77
|
|
76
78
|
/*
|
77
79
|
* Document-class: Iconv
|
@@ -217,10 +219,11 @@ map_charset(VALUE *code)
|
|
217
219
|
VALUE val = StringValue(*code);
|
218
220
|
|
219
221
|
if (RHASH_SIZE(charset_map)) {
|
220
|
-
|
222
|
+
VALUE data;
|
221
223
|
VALUE key = rb_funcall2(val, rb_intern("downcase"), 0, 0);
|
222
224
|
StringValuePtr(key);
|
223
|
-
|
225
|
+
data = rb_hash_aref(charset_map, key);
|
226
|
+
if(!NIL_P(data)) {
|
224
227
|
*code = (VALUE)data;
|
225
228
|
}
|
226
229
|
}
|
data/lib/iconv/version.rb
CHANGED
metadata
CHANGED
@@ -1,15 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: iconv
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
5
|
-
prerelease:
|
4
|
+
version: 1.0.4
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- NARUSE, Yui
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date: 2013-
|
11
|
+
date: 2013-12-08 00:00:00.000000000 Z
|
13
12
|
dependencies: []
|
14
13
|
description: iconv wrapper library
|
15
14
|
email:
|
@@ -39,36 +38,30 @@ files:
|
|
39
38
|
- test/utils.rb
|
40
39
|
homepage: https://github.com/nurse/iconv
|
41
40
|
licenses: []
|
41
|
+
metadata: {}
|
42
42
|
post_install_message:
|
43
43
|
rdoc_options: []
|
44
44
|
require_paths:
|
45
45
|
- lib
|
46
46
|
required_ruby_version: !ruby/object:Gem::Requirement
|
47
|
-
none: false
|
48
47
|
requirements:
|
49
|
-
- -
|
48
|
+
- - '>='
|
50
49
|
- !ruby/object:Gem::Version
|
51
50
|
version: '0'
|
52
|
-
segments:
|
53
|
-
- 0
|
54
|
-
hash: 832335822631035494
|
55
51
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
56
|
-
none: false
|
57
52
|
requirements:
|
58
|
-
- -
|
53
|
+
- - '>='
|
59
54
|
- !ruby/object:Gem::Version
|
60
55
|
version: '0'
|
61
|
-
segments:
|
62
|
-
- 0
|
63
|
-
hash: 832335822631035494
|
64
56
|
requirements: []
|
65
57
|
rubyforge_project:
|
66
|
-
rubygems_version:
|
58
|
+
rubygems_version: 2.0.2
|
67
59
|
signing_key:
|
68
|
-
specification_version:
|
60
|
+
specification_version: 4
|
69
61
|
summary: iconv wrapper library
|
70
62
|
test_files:
|
71
63
|
- test/test_basic.rb
|
72
64
|
- test/test_option.rb
|
73
65
|
- test/test_partial.rb
|
74
66
|
- test/utils.rb
|
67
|
+
has_rdoc:
|