import os

to_delete = [
	'session_stats',
	'libtorrent_logs*',
	'round_trip_ms.log',
	'dht.log',
	'upnp.log',
	'natpmp.log',
	'bin',
	'test_tmp_*'
]

directories = [
	'examples',
	'test',
	'.',
	'tools'
]

for d in directories:
	for f in to_delete:
		path = os.path.join(d, f)
		print path
		os.system('rm -rf %s' % path)


@@ -2,16 +2,30 @@
 mport os
+%0Aimport shutil
 %0A%0Ato_del
@@ -304,35 +304,51 @@
 h%0A%09%09
-os.system('rm -rf %25s' %25 path)
+try:%0A%09%09%09shutil.rmtree(path)%0A%09%09except:%0A%09%09%09pass
 %0A%0A

fix clean.py to be platform independent