diff options
| author | John Turner <jturner.usa@gmail.com> | 2025-11-19 01:00:48 +0000 |
|---|---|---|
| committer | John Turner <jturner.usa@gmail.com> | 2025-11-19 01:00:48 +0000 |
| commit | 70e8ea24a8ec9e3dfe484227463fdb97ee341227 (patch) | |
| tree | 1a19f0974b683c87e6e5c791252d5a5b99669b97 /scripts | |
| parent | e01637fd3a0a59ffea320a7df9770e73f486c91e (diff) | |
| download | gentoo-utils-70e8ea24a8ec9e3dfe484227463fdb97ee341227.tar.gz | |
impl vercmp fuzzer
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/vercmp.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/scripts/vercmp.py b/scripts/vercmp.py new file mode 100755 index 0000000..f02cb41 --- /dev/null +++ b/scripts/vercmp.py @@ -0,0 +1,14 @@ +#!/usr/bin/env python3 + +import sys +import portage + +for line in sys.stdin.buffer: + a, b = line.decode().split(" ") + + try: + sys.stdout.buffer.write(f"{portage.vercmp(a, b)}\n".encode()) + except: + sys.stdout.buffer.write(b"err\n") + finally: + sys.stdout.buffer.flush() |
