final touches on dkim test harness
[citadel.git] / webcit / openid.c
index 316859f8bef3e39764986a2c76883cb4e88a10eb..b56c01c2418b82e8ba2812dde0467062598a54b7 100644 (file)
@@ -1,23 +1,17 @@
 /*
- * Copyright (c) 1996-2011 by the citadel.org team
+ * Copyright (c) 1996-2012 by the citadel.org team
  *
  * This program is open source software.  You can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 3 of the
- * License, or (at your option) any later version.
+ * modify it under the terms of the GNU General Public License, version 3.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  */
 
 #include "webcit.h"
-#include "webserver.h"
+
 
 /*
  * Display the OpenIDs associated with an account
@@ -111,14 +105,14 @@ void openid_attach(void) {
  * Detach an OpenID from the currently logged-in account
  */
 void openid_detach(void) {
-       char buf[1024];
+       StrBuf *Line;
 
        if (havebstr("id_to_detach")) {
                serv_printf("OIDD %s", bstr("id_to_detach"));
-               serv_getln(buf, sizeof buf);
-               if (buf[0] != '2') {
-                       strcpy(WC->ImportantMessage, &buf[4]);
-               }
+               Line = NewStrBuf();
+               StrBuf_ServGetln(Line);
+               GetServerStatusMsg(Line, NULL, 1, 2);
+               FreeStrBuf(&Line);
        }
 
        display_openids();