summaryrefslogtreecommitdiff
path: root/dmyenc.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-12-03 05:51:28 (GMT)
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-12-03 05:51:28 (GMT)
commitf235dbeea5ca8aa9e433f3b1b5a8cc70970af304 (patch)
tree9be300c9fd4aa815d1d36a999ecb94c5d97141eb /dmyenc.c
parent49b3b2d8a2419199d28b4c1e660483bf2c92a74b (diff)
dmyenc.c: try to load encdb
* load.c (ruby_require_internal): separate from rb_require_safe, not to raise exceptions. * ruby.c (process_options): remove unnatural encoding search. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48696 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'dmyenc.c')
-rw-r--r--dmyenc.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/dmyenc.c b/dmyenc.c
index 53646ef..ec58043 100644
--- a/dmyenc.c
+++ b/dmyenc.c
@@ -1,4 +1,10 @@
+#define require(name) ruby_require_internal(name, (unsigned int)sizeof(name)-1)
+int ruby_require_internal(const char *, int);
+
void
Init_enc(void)
{
+ if (require("enc/encdb.so") == 0) {
+ require("enc/trans/transdb.so");
+ }
}