Commits

recursiveforest committed cdb182e Merge

Merge pull request #2 from lithium3141/master

Use os.path.join() to append path components

Comments (0)

Files changed (1)

 
 			if options.output and options.passkey and options.tracker and not options.notorrent:
 				if options.verbose: print('Creating torrent...')
-				torrent_command = 'mktorrent -p -a %s/announce -o "%s.torrent" "%s"' % (options.tracker + options.passkey, escape_backtick(options.torrent_dir + os.path.basename(mp3_dir)), mp3_dir)
+				torrent_command = 'mktorrent -p -a %s/announce -o "%s.torrent" "%s"' % (options.tracker + options.passkey, escape_backtick(os.path.join(options.torrent_dir, os.path.basename(mp3_dir))), mp3_dir)
 				if options.verbose: print(escape_backtick(torrent_command))
 				os.system(escape_backtick(torrent_command))