Sfoglia il codice sorgente

Return empty port when service undefined

Yentl Van Tendeloo 8 anni fa
parent
commit
552b912104
1 ha cambiato i file con 4 aggiunte e 0 eliminazioni
  1. 4 0
      bootstrap/services.alc

+ 4 - 0
bootstrap/services.alc

@@ -68,6 +68,10 @@ Element function comm_get(comm : String):
 String function comm_connect(service : String):
 	// Connect to an existing service
 	service = get_service_id(service)
+
+	if (service == ""):
+		return ""!
+
 	service = read_attribute(core, service, "port")
 
 	String port