Skip to content

Commit

Permalink
BAM: tiny upstream fix
Browse files Browse the repository at this point in the history
  • Loading branch information
sybrenstuvel committed Jun 10, 2017
1 parent 43e25b2 commit 8d5d983
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -645,6 +645,11 @@ def filename_filter(fname: bytes):
return filename_filter


def encode_none_safe(value: str):
if value is None:
return None
return value.encode('utf8')

def main():
parser = create_argparse()
args = parser.parse_args()
Expand All @@ -661,7 +666,7 @@ def report(msg):
args.path_src.encode('utf8'),
args.path_dst.encode('utf8'),
mode=args.mode,
base_dir_dst_temp=args.temp_path.encode('utf8'),
base_dir_dst_temp=encode_none_safe(args.temp_path),
filename_filter=exclusion_filter(args.exclude),
):
report(msg)
Expand Down

0 comments on commit 8d5d983

Please sign in to comment.