Use C99 uint32_t rather than u_int32_t
[onak.git] / cleankey.c
index f3110cc8efba3ccecb05e05deb97d69b1ac2bf49..d4046f3e47dd6529bdae02b78a222bacb4a2fe01 100644 (file)
@@ -1,12 +1,22 @@
 /*
  * cleankey.c - Routines to look for common key problems and clean them up.
  *
- * Jonathan McDowell <noodles@earth.li>
+ * Copyright 2004 Jonathan McDowell <noodles@earth.li>
  *
- * Copyright 2004 Project Purple
+ * This program is free 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; version 2 of the License.
+ *
+ * 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., 51
+ * Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  */
 
-#include <assert.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdlib.h>
@@ -31,7 +41,7 @@ int dedupuids(struct openpgp_publickey *key)
        struct openpgp_signedpacket_list *tmp = NULL;
        int                               merged = 0;
 
-       assert(key != NULL);
+       log_assert(key != NULL);
        curuid = key->uids;
        while (curuid != NULL) {
                dup = find_signed_packet(curuid->next, curuid->packet);
@@ -48,7 +58,7 @@ int dedupuids(struct openpgp_publickey *key)
                        while (tmp != NULL && tmp->next != dup) {
                                tmp = tmp->next;
                        }
-                       assert(tmp != NULL);
+                       log_assert(tmp != NULL);
                        tmp->next = dup->next;
                        dup->next = NULL;
                        free_signedpacket_list(dup);