From: Adam Megacz Date: Mon, 27 Jul 2009 03:21:26 +0000 (-0700) Subject: LoopFactory: fix bug that occurs when sendWord(null) is called X-Git-Url: http://git.megacz.com/?p=fleet.git;a=commitdiff_plain;h=4165a81ddd050385ef8705f4ff9a87be85fc01d9 LoopFactory: fix bug that occurs when sendWord(null) is called --- diff --git a/src/edu/berkeley/fleet/loops/LoopFactory.java b/src/edu/berkeley/fleet/loops/LoopFactory.java index 5bdfc2a..1e79135 100644 --- a/src/edu/berkeley/fleet/loops/LoopFactory.java +++ b/src/edu/berkeley/fleet/loops/LoopFactory.java @@ -224,7 +224,7 @@ public class LoopFactory { public void sendWord(Destination dest, BitVector signal) { if (!dock.isOutputDock()) throw new RuntimeException("sendWord() may only be used at output docks"); if (pending_sendToken) flush_pending(); - pending_path = dock.getPath(dest, signal); + pending_path = dest==null ? null : dock.getPath(dest, signal); flush_pending(true); } public void sendWord(Dock dock) { sendWord(dock.getDataDestination()); }