From 30c85e95199e4e0cc5b716ab8580be205a8ee15d Mon Sep 17 00:00:00 2001 From: yugui Date: Thu, 29 Jan 2009 17:14:18 +0000 Subject: merges r21875 from trunk into ruby_1_9_1. * load.c (rb_feature_provided): should not calculate len by pointer subtraction because feature may be a expanded path. [ruby-core:21267] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@21881 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- load.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'load.c') diff --git a/load.c b/load.c index 8693aef8a..8e66a7571 100644 --- a/load.c +++ b/load.c @@ -128,8 +128,8 @@ rb_feature_p(const char *feature, const char *ext, int rb, int expanded, const c if (fn) *fn = 0; if (ext) { - len = ext - feature; elen = strlen(ext); + len = strlen(feature) - elen; type = rb ? 'r' : 's'; } else { -- cgit