* make shure the buffer is cleared
[citadel.git] / webcit / useredit.c
index e14a53a721bb693c43962c51462591aa60517f10..b1d2479fe73024fec01fd32ec7ba4ca8f7f65501 100644 (file)
@@ -467,6 +467,7 @@ TRYAGAIN:
 
        /* If there's no vcard, create one */
        if ((*VCMsg == NULL) && (already_tried_creating_one == 0)) {
+               FlushStrBuf(Buf);
                already_tried_creating_one = 1;
                serv_puts("ENT0 1|||4");
                StrBuf_ServGetln(Buf);
@@ -477,6 +478,8 @@ TRYAGAIN:
                        serv_puts("end:vcard");
                        serv_puts("000");
                }
+               else 
+                       lprintf(1, "Error while creating user vcard: %s\n", ChrPtr(Buf));
                goto TRYAGAIN;
        }
        FreeStrBuf(&Buf);