aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/oauth2.c3
-rw-r--r--lib/xmltree.c3
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/oauth2.c b/lib/oauth2.c
index 62db3500..6921a6d5 100644
--- a/lib/oauth2.c
+++ b/lib/oauth2.c
@@ -102,7 +102,7 @@ static void oauth2_access_token_done( struct http_request *req )
{
struct oauth2_access_token_data *cb_data = req->data;
char *atoken = NULL, *rtoken = NULL;
- const char *content_type;
+ char *content_type;
if( getenv( "BITLBEE_DEBUG" ) && req->reply_body )
printf( "%s\n", req->reply_body );
@@ -145,6 +145,7 @@ static void oauth2_access_token_done( struct http_request *req )
printf( "Extracted atoken=%s rtoken=%s\n", atoken, rtoken );
cb_data->func( cb_data->data, atoken, rtoken );
+ g_free( content_type );
g_free( atoken );
g_free( rtoken );
g_free( cb_data );
diff --git a/lib/xmltree.c b/lib/xmltree.c
index 3ecb2b93..f79c53da 100644
--- a/lib/xmltree.c
+++ b/lib/xmltree.c
@@ -162,9 +162,8 @@ int xt_handle( struct xt_parser *xt, struct xt_node *node, int depth )
xt_status st;
int i;
- /* Just in case someone likes infinite loops... */
if( xt->root == NULL )
- return 0;
+ return 1;
if( node == NULL )
return xt_handle( xt, xt->root, depth );