[vlma-devel] commit: Avoid NullPointerException when programming something else than VoD . (Adrien Grand )

git version control git at videolan.org
Sun Oct 12 15:18:51 CEST 2008


vlma | branch: master | Adrien Grand <jpountz at videolan.org> | Sun Oct 12 15:14:55 2008 +0200| [0a0051d44813f0ee0888b4bbf52df15b1005c5b6] | committer: Adrien Grand 

Avoid NullPointerException when programming something else than VoD.

> http://git.videolan.org/gitweb.cgi/vlma.git/?a=commit;h=0a0051d44813f0ee0888b4bbf52df15b1005c5b6
---

 .../java/org/videolan/vlma/order/OrderSender.java  |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/vlma-core/src/main/java/org/videolan/vlma/order/OrderSender.java b/vlma-core/src/main/java/org/videolan/vlma/order/OrderSender.java
index afc91ed..300562d 100644
--- a/vlma-core/src/main/java/org/videolan/vlma/order/OrderSender.java
+++ b/vlma-core/src/main/java/org/videolan/vlma/order/OrderSender.java
@@ -141,7 +141,8 @@ public abstract class OrderSender {
         telnetCommand("control " + commandName + " stop", adapter);
         telnetCommand("del " + commandName, adapter);
         // Create a vod program
-        if(streamingStrategy.getProtocol() == StreamingStrategy.Protocol.VOD)
+        if(streamingStrategy != null
+                && streamingStrategy.getProtocol() == StreamingStrategy.Protocol.VOD)
         	telnetCommand("new " + commandName + " vod", adapter);
         else // Create a multicast diffusion program
         	telnetCommand("new " + commandName + " broadcast", adapter);



More information about the vlma-devel mailing list