def shortenfile(item):
    'Shave some data off the end of file.'
    temp = bytearray((2 ** 19))
    with open(item, 'rb') as fd:
        fd.readinto(temp)
    with open(item, 'wb') as fd:
        fd.write(temp)
Shave some data off the end of file.
def shortenfile(item):
    
    temp = bytearray((2 ** 19))
    with open(item, 'rb') as fd:
        fd.readinto(temp)
    with open(item, 'wb') as fd:
        fd.write(temp)