Mercurial > hgrepos > Python2 > PyMuPDF
changeset 22:d77477b4e151
Let _int_rc() also handle (i.e. ignore) a local version suffix
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Fri, 19 Sep 2025 12:05:57 +0200 |
| parents | 2f43e400f144 |
| children | 3b13504f9d89 |
| files | src/__init__.py |
| diffstat | 1 files changed, 6 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/__init__.py Fri Sep 19 10:28:53 2025 +0200 +++ b/src/__init__.py Fri Sep 19 12:05:57 2025 +0200 @@ -366,8 +366,12 @@ def _int_rc(text): ''' - Converts string to int, ignoring trailing 'rc...'. - ''' + Converts string to int, ignoring trailing 'rc...' and a trailing + local version. + ''' + rc = text.find('+') + if rc >= 0: + text = text[:rc] rc = text.find('rc') if rc >= 0: text = text[:rc]
