def merge_status(main, other):
    """
    Merge two status tuples.
    """
    new_code = main[0] | other[0]
    new_out = '%s%s' % (main[1], other[1])
    new_err = '%s%s' % (main[2], other[2])
    return new_code, new_out, new_err
