diff options
author | shugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-01-29 07:32:07 +0000 |
---|---|---|
committer | shugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-01-29 07:32:07 +0000 |
commit | 1a89baadd3956e3ac185b95796c84c89d7da2519 (patch) | |
tree | 4b1634de97526de0339b1f6c5add487f1dd941ca /load.c | |
parent | 094a247a04cec7078a84a3b4259ead9a711da347 (diff) |
* 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: svn+ssh://ci.ruby-lang.org/ruby/trunk@21875 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'load.c')
-rw-r--r-- | load.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -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 { |