diff options
author | Maxim Sobolev <sobomax@FreeBSD.org> | 2001-07-31 07:41:01 +0000 |
---|---|---|
committer | Maxim Sobolev <sobomax@FreeBSD.org> | 2001-07-31 07:41:01 +0000 |
commit | a2bc5891ae1cee8415df8cb019c9758b5b6cfe15 (patch) | |
tree | 82ad14fdcdec85fcf91a08f18574a8a7fb91ea98 /Tools/scripts/patchtool.py | |
parent | d2911a79af558061d6eaab3572b421e41f61a302 (diff) | |
download | ports-a2bc5891ae1cee8415df8cb019c9758b5b6cfe15.tar.gz ports-a2bc5891ae1cee8415df8cb019c9758b5b6cfe15.zip |
Notes
Diffstat (limited to 'Tools/scripts/patchtool.py')
-rwxr-xr-x | Tools/scripts/patchtool.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Tools/scripts/patchtool.py b/Tools/scripts/patchtool.py index 08f8f528851d..845a7ff92c6c 100755 --- a/Tools/scripts/patchtool.py +++ b/Tools/scripts/patchtool.py @@ -157,6 +157,8 @@ def getrelpath(path, wrksrc): path = os.path.abspath(path) wrksrc = os.path.abspath(wrksrc) commonpart = os.path.commonprefix((path, wrksrc)) + while commonpart[-1:] != '/': + commonpart = commonpart[:-1] path = path[len(commonpart):] wrksrc = wrksrc[len(commonpart):] if wrksrc == '': |