diff options
author | Edwin Mons <edwin.mons@isode.com> | 2013-11-18 09:49:04 (GMT) |
---|---|---|
committer | Edwin Mons <edwin.mons@isode.com> | 2013-11-18 19:56:19 (GMT) |
commit | 3dfd467727be84089dd8c39aac2df4f7ee9b43aa (patch) | |
tree | a5587189a27fc816e30517b6a731d5ed860232cb | |
parent | ec57e1f727d3b8d64ca5bf60f2bd277cd0f23f21 (diff) | |
download | swift-3dfd467727be84089dd8c39aac2df4f7ee9b43aa.zip swift-3dfd467727be84089dd8c39aac2df4f7ee9b43aa.tar.bz2 |
Sluift: add bosh_url client option
Change-Id: I42b14f411531f8814bbb85f3941772a4149c4171
-rw-r--r-- | Sluift/client.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Sluift/client.cpp b/Sluift/client.cpp index 04ce8f4..d6f876f 100644 --- a/Sluift/client.cpp +++ b/Sluift/client.cpp @@ -340,6 +340,10 @@ SLUIFT_LUA_FUNCTION(Client, set_options) { bool useTLS = lua_toboolean(L, -1); client->getOptions().useTLS = (useTLS ? ClientOptions::UseTLSWhenAvailable : ClientOptions::NeverUseTLS); } + lua_getfield(L, 2, "bosh_url"); + if (!lua_isnil(L, -1)) { + client->getOptions().boshURL = URL::fromString(lua_tostring(L, -1)); + } lua_pushvalue(L, 1); return 0; } |