summaryrefslogtreecommitdiff
path: root/logbot.py
diff options
context:
space:
mode:
authorChris Oliver <excid3@gmail.com>2012-01-19 13:18:10 -0600
committerChris Oliver <excid3@gmail.com>2012-01-19 13:18:10 -0600
commita7f48ea6cc2f13450fe58db008ad4b3cbd5deb4e (patch)
treeb66aef92eb1964b8189397da091998a770f56a2d /logbot.py
parent1700265b187bc23d17618df90fa52131b4dd5883 (diff)
downloadlogbot-a7f48ea6cc2f13450fe58db008ad4b3cbd5deb4e.tar.xz
Use python path splitting to allow windows filename parsing
Diffstat (limited to 'logbot.py')
-rw-r--r--logbot.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/logbot.py b/logbot.py
index 5af885a..0b9eb8e 100644
--- a/logbot.py
+++ b/logbot.py
@@ -205,9 +205,8 @@ class Logbot(SingleServerIRCBot):
for fname in files:
full_fname = os.path.join(root, fname)
- remote_fname = "/".join(full_fname.split("/")[1:])
+ remote_fname = "/".join(os.path.split(full_fname)[1:])
if DEBUG: print repr(remote_fname)
- if not remote_fname: continue
try:
self.ftp.storbinary("STOR %s" % remote_fname, open(full_fname, "rb"))
except ftplib.error_perm, e: