Recommit "rL366894: [yaml2obj] - Allow custom fields for the SHT_UNDEF sections."
[llvm-complete.git] / test / tools / llvm-objcopy / Inputs / ungzip.py
blobc7b1de96b25c439707ef2d56423885c0286fd90b
1 import gzip
2 import sys
4 with gzip.open(sys.argv[1], 'rb') as f:
5 writer = getattr(sys.stdout, 'buffer', None)
6 if writer is None:
7 writer = sys.stdout
8 if sys.platform == "win32":
9 import os, msvcrt
10 msvcrt.setmode(sys.stdout.fileno(),os.O_BINARY)
12 writer.write(f.read())
13 sys.stdout.flush()