pidgin/pidgin

novell: Remove unused data/code.

2019-11-02, Elliott Sales de Andrade
1f2ef108cfcb
Parents 5fd446031612
Children 349378b539ca
novell: Remove unused data/code.
--- a/libpurple/protocols/novell/nmconn.c Sat Nov 02 16:33:36 2019 -0400
+++ b/libpurple/protocols/novell/nmconn.c Sat Nov 02 16:40:40 2019 -0400
@@ -23,7 +23,6 @@
#include <errno.h>
#include <string.h>
#include <ctype.h>
-#include <time.h>
#include "nmconn.h"
#ifdef _WIN32
@@ -455,8 +454,8 @@
/* Create a request struct, add it to our queue, and return it */
if (rc == NM_OK) {
- NMRequest *new_request = nm_create_request(cmd, conn->trans_id,
- time(0), cb, NULL, data);
+ NMRequest *new_request =
+ nm_create_request(cmd, conn->trans_id, cb, NULL, data);
nm_conn_add_request_item(conn, new_request);
/* Set the out param if it was sent in, otherwise release the request */
@@ -663,21 +662,3 @@
}
return NULL;
}
-
-const char *
-nm_conn_get_addr(NMConn * conn)
-{
- if (conn == NULL)
- return NULL;
- else
- return conn->addr;
-}
-
-int
-nm_conn_get_port(NMConn * conn)
-{
- if (conn == NULL)
- return -1;
- else
- return conn->port;
-}
--- a/libpurple/protocols/novell/nmconn.h Sat Nov 02 16:33:36 2019 -0400
+++ b/libpurple/protocols/novell/nmconn.h Sat Nov 02 16:40:40 2019 -0400
@@ -45,12 +45,6 @@
/* A list of requests currently awaiting a response. */
GSList *requests;
- /* Are we connected? TRUE if so, FALSE if not. */
- gboolean connected;
-
- /* Have we been redirected? */
- gboolean redirect;
-
/* SSL connection */
NMSSLConn *ssl_conn;
@@ -218,23 +212,4 @@
*/
NMRequest *nm_conn_find_request(NMConn * conn, int trans_id);
-/**
- * Get the server address for the connection.
- *
- * @param conn The connection.
- *
- * @return The server address for the connection.
- *
- */
-const char *nm_conn_get_addr(NMConn * conn);
-
-/**
- * Get the port for the connection.
- *
- * @param conn The connection.
- *
- * @return The port that we are connected to.
- */
-int nm_conn_get_port(NMConn * conn);
-
#endif /* PURPLE_NOVELL_NMCONN_H */
--- a/libpurple/protocols/novell/nmrequest.c Sat Nov 02 16:33:36 2019 -0400
+++ b/libpurple/protocols/novell/nmrequest.c Sat Nov 02 16:40:40 2019 -0400
@@ -26,16 +26,15 @@
{
int trans_id;
char *cmd;
- int gmt;
gpointer data;
gpointer user_define;
nm_response_cb callback;
int ref_count;
- NMERR_T ret_code;
};
-NMRequest *nm_create_request(const char *cmd, int trans_id, int gmt, nm_response_cb cb,
- gpointer resp_data, gpointer user_define)
+NMRequest *
+nm_create_request(const char *cmd, int trans_id, nm_response_cb cb,
+ gpointer resp_data, gpointer user_define)
{
NMRequest *req;
@@ -45,7 +44,6 @@
req = g_new0(NMRequest, 1);
req->cmd = g_strdup(cmd);
req->trans_id = trans_id;
- req->gmt = gmt;
req->callback = cb;
req->data = resp_data;
req->user_define = user_define;
@@ -141,20 +139,3 @@
return req->callback;
}
-
-
-void
-nm_request_set_ret_code(NMRequest * req, NMERR_T rc)
-{
- if (req)
- req->ret_code = rc;
-}
-
-NMERR_T
-nm_request_get_ret_code(NMRequest * req)
-{
- if (req)
- return req->ret_code;
- else
- return (NMERR_T) - 1;
-}
--- a/libpurple/protocols/novell/nmrequest.h Sat Nov 02 16:33:36 2019 -0400
+++ b/libpurple/protocols/novell/nmrequest.h Sat Nov 02 16:40:40 2019 -0400
@@ -30,12 +30,11 @@
*
* @param cmd The request command string (e.g. "login")
* @param trans_id The request transaction id
- * @param gmt The time in seconds that the request was created
*
* @return The new request object
*/
-NMRequest *nm_create_request(const char *cmd, int trans_id, int gmt, nm_response_cb cb,
- gpointer resp_data, gpointer user_define);
+NMRequest *nm_create_request(const char *cmd, int trans_id, nm_response_cb cb,
+ gpointer resp_data, gpointer user_define);
/**
* Release a request object.
@@ -85,15 +84,6 @@
void nm_request_set_user_define(NMRequest * req, gpointer user_define);
/**
- * Set the return code. This is the return code that we received in
- * the server response fields.
- *
- * @param req The request object
- * @param rc The return code to set
- */
-void nm_request_set_ret_code(NMRequest * req, NMERR_T rc);
-
-/**
* Get the transaction id for this request.
*
* @param req The request object
@@ -138,13 +128,4 @@
*/
nm_response_cb nm_request_get_callback(NMRequest * req);
-/**
- * Get the return code
- *
- * @param req The request object
- *
- * @return The return code (from the response fields)
- */
-NMERR_T nm_request_get_ret_code(NMRequest * req);
-
#endif /* PURPLE_NOVELL_NMREQUEST_H */
--- a/libpurple/protocols/novell/nmuser.h Sat Nov 02 16:33:36 2019 -0400
+++ b/libpurple/protocols/novell/nmuser.h Sat Nov 02 16:40:40 2019 -0400
@@ -81,9 +81,6 @@
/* Our connection information */
NMConn *conn;
- /* Our public IP address */
- char *address;
-
/* This is the contact list */
NMFolder *root_folder;
@@ -110,15 +107,6 @@
GSList *allow_list;
GSList *deny_list;
- /* Pending requests. If we need to go to the server to more info
- * before processing a request we will queue it up and process when
- * we get a response
- */
- GSList *pending_requests;
-
- /* Pending events. Same as above except for events. */
- GSList *pending_events;
-
/* Generic pointer to data needed by the client
* using the API
*/
--- a/libpurple/protocols/novell/novell.c Sat Nov 02 16:33:36 2019 -0400
+++ b/libpurple/protocols/novell/novell.c Sat Nov 02 16:40:40 2019 -0400
@@ -1743,7 +1743,6 @@
rc = nm_send_login(user, pwd, my_addr, ua, _login_resp_cb, NULL);
if (rc == NM_OK) {
- conn->connected = TRUE;
purple_ssl_input_add(gsc, novell_ssl_recv_cb, gc);
} else {
purple_connection_error(gc,