Commit bbb81490 authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

New version that fixes incompatibility with PostgreSQL

git-svn-id: http://svn.igniterealtime.org/svn/repos/openfire/trunk@9471 b35dd754-fafc-0310-a699-88a17e54d16e
parent b327b1f2
...@@ -44,12 +44,17 @@ ...@@ -44,12 +44,17 @@
SIP Plugin Changelog SIP Plugin Changelog
</h1> </h1>
<p><b>1.0.1</b> -- November 9, 2007</p>
<ul>
<li>Fixed incompatibility with PostgreSQL and possibly other databases too.</li>
</ul>
<p><b>1.0.0</b> -- October 31, 2007</p> <p><b>1.0.0</b> -- October 31, 2007</p>
<ul> <ul>
<li>Initial release.</li> <li>Initial release.</li>
</ul> </ul>
</body> </body>
</html> </html>
\ No newline at end of file
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
<name>SIP Phone Plugin</name> <name>SIP Phone Plugin</name>
<description>Provides support for SIP account management</description> <description>Provides support for SIP account management</description>
<author>Ignite Realtime</author> <author>Ignite Realtime</author>
<version>1.0.0</version> <version>1.0.1</version>
<date>10/31/2007</date> <date>11/9/2007</date>
<databaseKey>sip</databaseKey> <databaseKey>sip</databaseKey>
<databaseVersion>1</databaseVersion> <databaseVersion>1</databaseVersion>
<minServerVersion>3.3.0</minServerVersion> <minServerVersion>3.3.0</minServerVersion>
......
...@@ -72,11 +72,11 @@ public class SipAccountDAO { ...@@ -72,11 +72,11 @@ public class SipAccountDAO {
String server = rs.getString("sipserver"); String server = rs.getString("sipserver");
String stunServer = rs.getString("stunserver"); String stunServer = rs.getString("stunserver");
String stunPort = rs.getString("stunport"); String stunPort = rs.getString("stunport");
boolean useStun = rs.getBoolean("usestun"); boolean useStun = rs.getInt("usestun") == 1;
boolean enabled = rs.getBoolean("enabled"); boolean enabled = rs.getInt("enabled") == 1;
String voicemail = rs.getString("voicemail"); String voicemail = rs.getString("voicemail");
String outboundproxy = rs.getString("outboundproxy"); String outboundproxy = rs.getString("outboundproxy");
boolean promptCredentials = rs.getBoolean("promptCredentials"); boolean promptCredentials = rs.getInt("promptCredentials") == 1;
SipRegisterStatus status = SipRegisterStatus.valueOf(rs.getString("status")); SipRegisterStatus status = SipRegisterStatus.valueOf(rs.getString("status"));
sipAccount = new SipAccount(username); sipAccount = new SipAccount(username);
...@@ -118,14 +118,14 @@ public class SipAccountDAO { ...@@ -118,14 +118,14 @@ public class SipAccountDAO {
psmt.setString(4, sipAccount.getDisplayName()); psmt.setString(4, sipAccount.getDisplayName());
psmt.setString(5, sipAccount.getPassword()); psmt.setString(5, sipAccount.getPassword());
psmt.setString(6, sipAccount.getServer()); psmt.setString(6, sipAccount.getServer());
psmt.setBoolean(7, sipAccount.isEnabled()); psmt.setInt(7, sipAccount.isEnabled() ? 1 : 0);
psmt.setString(8, sipAccount.getStatus().name()); psmt.setString(8, sipAccount.getStatus().name());
psmt.setString(9, sipAccount.getStunServer()); psmt.setString(9, sipAccount.getStunServer());
psmt.setString(10, sipAccount.getStunPort()); psmt.setString(10, sipAccount.getStunPort());
psmt.setBoolean(11, sipAccount.isUseStun()); psmt.setInt(11, sipAccount.isUseStun() ? 1 : 0);
psmt.setString(12, sipAccount.getVoiceMailNumber()); psmt.setString(12, sipAccount.getVoiceMailNumber());
psmt.setString(13, sipAccount.getOutboundproxy()); psmt.setString(13, sipAccount.getOutboundproxy());
psmt.setBoolean(14, sipAccount.isPromptCredentials()); psmt.setInt(14, sipAccount.isPromptCredentials() ? 1 : 0);
psmt.executeUpdate(); psmt.executeUpdate();
} catch (SQLException e) { } catch (SQLException e) {
...@@ -154,14 +154,14 @@ public class SipAccountDAO { ...@@ -154,14 +154,14 @@ public class SipAccountDAO {
psmt.setString(3, sipAccount.getDisplayName()); psmt.setString(3, sipAccount.getDisplayName());
psmt.setString(4, sipAccount.getPassword()); psmt.setString(4, sipAccount.getPassword());
psmt.setString(5, sipAccount.getServer()); psmt.setString(5, sipAccount.getServer());
psmt.setBoolean(6, sipAccount.isEnabled()); psmt.setInt(6, sipAccount.isEnabled() ? 1 : 0);
psmt.setString(7, sipAccount.getStatus().name()); psmt.setString(7, sipAccount.getStatus().name());
psmt.setString(8, sipAccount.getStunServer()); psmt.setString(8, sipAccount.getStunServer());
psmt.setString(9, sipAccount.getStunPort()); psmt.setString(9, sipAccount.getStunPort());
psmt.setBoolean(10, sipAccount.isUseStun()); psmt.setInt(10, sipAccount.isUseStun() ? 1 : 0);
psmt.setString(11, sipAccount.getVoiceMailNumber()); psmt.setString(11, sipAccount.getVoiceMailNumber());
psmt.setString(12, sipAccount.getOutboundproxy()); psmt.setString(12, sipAccount.getOutboundproxy());
psmt.setBoolean(13, sipAccount.isPromptCredentials()); psmt.setInt(13, sipAccount.isPromptCredentials() ? 1 : 0);
psmt.setString(14, sipAccount.getUsername()); psmt.setString(14, sipAccount.getUsername());
psmt.executeUpdate(); psmt.executeUpdate();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment