[vlc-devel] commit: Don't print welcome message if it's empty. (Antoine Cellerier )

git version control git at videolan.org
Sun Dec 27 23:19:46 CET 2009


vlc | branch: master | Antoine Cellerier <dionoea at videolan.org> | Sun Dec 27 21:14:17 2009 +0100| [621afc68d4cb5aff9e463f5161decd1396e94af2] | committer: Antoine Cellerier 

Don't print welcome message if it's empty.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=621afc68d4cb5aff9e463f5161decd1396e94af2
---

 share/lua/intf/rc.lua |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/share/lua/intf/rc.lua b/share/lua/intf/rc.lua
index 2fd30ee..6acbfed 100644
--- a/share/lua/intf/rc.lua
+++ b/share/lua/intf/rc.lua
@@ -562,7 +562,7 @@ do
         end
     end
     list = list..")"
-    if count ~= 0 and env.welcome then
+    if count ~= 0 and env.welcome and env.welcome ~= "" then
         env.welcome = env.welcome .. "\r\nWarning: "..count.." functions are still unimplemented "..list.."."
     end
 end
@@ -623,7 +623,9 @@ h = host.host()
 -- No auth
 h.status_callbacks[host.status.password] = function(client)
     client.env = common.table_copy( env )
-    client:send( client.env.welcome .. "\r\n")
+    if client.env.welcome ~= "" then
+        client:send( client.env.welcome .. "\r\n")
+    end
     client:switch_status(host.status.read)
 end
 -- Print prompt when switching a client's status to `read'




More information about the vlc-devel mailing list