Cleaned up the Python module a bit.
[doldaconnect.git] / lib / python / dolmod.c
index fd026fa..c8df522 100644 (file)
@@ -235,7 +235,7 @@ static int qcmd_cb(struct dc_response *resp)
 
 static PyObject *mod_qcmd(PyObject *self, PyObject *args, PyObject *kwargs)
 {
-    int i, tag;
+    int i;
     wchar_t **toks, *tok, *cmd;
     size_t tokssize, toksdata, toksize;
     PyObject *c, *n, *cb, *ret;
@@ -310,6 +310,9 @@ static void login_cb(int err, wchar_t *reason, PyObject *cb)
     case DC_LOGIN_ERR_AUTHFAIL:
        errstr = "authfail";
        break;
+    default:
+       errstr = "unknown";
+       break;
     }
     pyerr = PyString_FromString(errstr);
     if(reason == NULL)