[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
gEDA-cvs: xgsch2pcb.git: branch: master updated (rel_0.1.2-5-ge416739)
The branch, master has been updated
via e4167391f1cb1b127278a9dc22849051d40b99c0 (commit)
via 386a2fd3bc971a1b42695b930c3e7c3930d13dbd (commit)
from 4d571037066113c9d372a7bf71560dcd9cd988e5 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
=========
Summary
=========
lib/xgsch2pcb/gsch2pcbproject.py | 10 ++++++++--
lib/xgsch2pcb/pcbmanager.py | 2 +-
2 files changed, 9 insertions(+), 3 deletions(-)
=================
Commit Messages
=================
commit e4167391f1cb1b127278a9dc22849051d40b99c0
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date: Tue Mar 10 16:18:47 2009 +0000
Handle blank lines in the project file correctly.
Blank project file lines split up to give a zero length array
of tokens. Don't try to access the array if it is empty.
:100644 100644 989e30d... bb75428... M lib/xgsch2pcb/gsch2pcbproject.py
commit 386a2fd3bc971a1b42695b930c3e7c3930d13dbd
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date: Tue Mar 10 16:00:39 2009 +0000
Pick the correct PCB instance when multiple are open
Instead of breaking out of the loop over PCB instances when we found
the right one we continue'd looping. Whoops!
:100644 100644 99d76b0... 5e81361... M lib/xgsch2pcb/pcbmanager.py
=========
Changes
=========
commit e4167391f1cb1b127278a9dc22849051d40b99c0
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date: Tue Mar 10 16:18:47 2009 +0000
Handle blank lines in the project file correctly.
Blank project file lines split up to give a zero length array
of tokens. Don't try to access the array if it is empty.
diff --git a/lib/xgsch2pcb/gsch2pcbproject.py b/lib/xgsch2pcb/gsch2pcbproject.py
index 989e30d..bb75428 100644
--- a/lib/xgsch2pcb/gsch2pcbproject.py
+++ b/lib/xgsch2pcb/gsch2pcbproject.py
@@ -71,7 +71,10 @@ class Gsch2PCBProject(gobject.GObject):
for line in fp:
self.lines.append(line)
parts = line.strip().split(None, 1)
- opt = parts[0]
+
+ opt = None
+ if parts:
+ opt = parts[0]
# Skip blank lines and comment lines (like gsch2pcb)
if not opt or opt[0] == '#' or opt[0] == '/' or opt[0] == ';':
@@ -103,7 +106,10 @@ class Gsch2PCBProject(gobject.GObject):
fp = open(destfile, 'wb')
for line in self.lines:
parts = line.strip().split(None, 1)
- opt = parts[0]
+ opt = None
+ if parts:
+ opt = parts[0]
+
if opt == 'schematics':
fp.write('schematics %s\n' % ' '.join(self.pages))
emitted_schematics = True
commit 386a2fd3bc971a1b42695b930c3e7c3930d13dbd
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date: Tue Mar 10 16:00:39 2009 +0000
Pick the correct PCB instance when multiple are open
Instead of breaking out of the loop over PCB instances when we found
the right one we continue'd looping. Whoops!
diff --git a/lib/xgsch2pcb/pcbmanager.py b/lib/xgsch2pcb/pcbmanager.py
index 99d76b0..5e81361 100644
--- a/lib/xgsch2pcb/pcbmanager.py
+++ b/lib/xgsch2pcb/pcbmanager.py
@@ -126,7 +126,7 @@ class PCBManager( gobject.GObject ):
if filename == os.path.abspath( self.output_name ) + ".pcb":
found_our_file = True
- continue
+ break
if not found_our_file:
return False
_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs