changes for narrow/wide prototypes
authorJohn Kohl <jtkohl@mit.edu>
Mon, 19 Nov 1990 14:05:49 +0000 (14:05 +0000)
committerJohn Kohl <jtkohl@mit.edu>
Mon, 19 Nov 1990 14:05:49 +0000 (14:05 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@1461 dc483132-0cff-0310-8789-dd5450dbe970

src/admin/edit/kdb5_edit.c
src/include/krb5/asn.1/asn1defs.h
src/lib/crypto/des/des_int.h
src/lib/kdb/kdb_dbm.c
src/lib/krb5/keytab/file/ktfile.h
src/lib/krb5/krb/rd_req.c
src/lib/krb5/krb/rd_req_dec.c

index 7c8e929aaed93619f8118abb722e32c2dcb82bc5..c970162b28a1a35d509b135e8811d3dc4297daff 100644 (file)
@@ -47,14 +47,17 @@ struct mblock {
     0
 };
 
+/* krb5_kvno may be narrow */
+#include <krb5/widen.h>
 void add_key PROTOTYPE((char * const *, krb5_const_principal,
                        const krb5_keyblock *, krb5_kvno));
 void enter_rnd_key PROTOTYPE((char **, const krb5_principal, krb5_kvno));
 void enter_pwd_key PROTOTYPE((char **, krb5_const_principal,
                              krb5_const_principal, krb5_kvno));
-
 int set_dbname_help PROTOTYPE((char *, char *));
 
+#include <krb5/narrow.h>
+
 static void
 usage(who, status)
 char *who;
index b4a0e5cd27b0ba864f7d2fa8d3215cd7e270c5fc..eb7a80b544882e47f1c89a8644f49e668d70f16c 100644 (file)
@@ -138,12 +138,6 @@ struct type_KRB5_KRB__ERROR *krb5_error2KRB5_KRB__ERROR
 struct type_KRB5_EncTicketPart *krb5_enc_tkt_part2KRB5_EncTicketPart
        PROTOTYPE((const krb5_enc_tkt_part *, int *));
 
-/* kkdcr2kdcr.c */
-struct type_KRB5_TGS__REP *krb5_kdc_rep2KRB5_KDC__REP
-       PROTOTYPE((const krb5_kdc_rep *,
-                  const krb5_msgtype,
-                  int *));
-
 /* kkey2enck.c */
 struct type_KRB5_EncryptionKey *krb5_keyblock2KRB5_EncryptionKey
        PROTOTYPE((const krb5_keyblock *, int *));
@@ -226,4 +220,17 @@ struct type_KRB5_TicketFlags *krb5_flags2KRB5_TicketFlags
 krb5_flags KRB5_TicketFlags2krb5_flags
        PROTOTYPE((const struct type_KRB5_TicketFlags *,int *));
 
+#include <krb5/widen.h>
+
+/* Only put things which don't have pointers to the narrow types in this
+   section */
+
+/* kkdcr2kdcr.c */
+struct type_KRB5_TGS__REP *krb5_kdc_rep2KRB5_KDC__REP
+       PROTOTYPE((const krb5_kdc_rep *,
+                  const krb5_msgtype,
+                  int *));
+
+#include <krb5/narrow.h>
+
 #endif /* KRB5_ASN1DEFS__ */
index dc78917bc95a22bbefeda90ee66fd3564ff26f63..09fb53a7fefbaca6be2ff0c0352b3008e8461324 100644 (file)
@@ -91,6 +91,9 @@ typedef struct {
 #endif /*BITS32*/
 
 
+/* widen prototypes, if needed */
+#include <krb5/widen.h>
+
 /* cbc_cksum.c */
 extern krb5_error_code mit_des_cbc_checksum
     PROTOTYPE((krb5_pointer, size_t,krb5_pointer,size_t, krb5_checksum * ));
@@ -178,5 +181,7 @@ extern unsigned long swap_long_bytes_bit_number PROTOTYPE((unsigned long ));
 extern void test_set PROTOTYPE((FILE *, const char *, int, const char *, int));
 #endif
 
-#undef P
+/* and back to normal... */
+#include <krb5/narrow.h>
+
 #endif /*DES_INTERNAL_DEFS*/
index 7499dad01b4866ad04e875262c5ffc059c0c38a2..ff448b3c37c246059870c586fe290267a4666a71 100644 (file)
@@ -971,8 +971,8 @@ krb5_pointer func_arg;
 }
 
 krb5_boolean
-krb5_dbm_db_set_lockmode(mode)
-    krb5_boolean mode;
+krb5_dbm_db_set_lockmode(DECLARG(krb5_boolean,mode))
+OLDDECLARG(krb5_boolean,mode)
 {
     krb5_boolean old = non_blocking;
     non_blocking = mode;
index 3c1517ee89fed9f6810e4a5344d71d1bc25b89d3..83d9ec2c00317abd030dfe6c625e142bc02d34f3 100644 (file)
@@ -42,6 +42,10 @@ typedef struct _krb5_ktfile_data {
 
 extern struct _krb5_kt_ops krb5_ktf_ops;
 extern struct _krb5_kt_ops krb5_ktf_writable_ops;
+
+/* widen prototypes, if needed */
+#include <krb5/widen.h>
+
 krb5_error_code krb5_ktfile_resolve PROTOTYPE((char *,
                                               krb5_keytab *));
 krb5_error_code krb5_ktfile_wresolve PROTOTYPE((char *,
@@ -74,5 +78,7 @@ krb5_error_code krb5_ktfileint_read_entry PROTOTYPE((krb5_keytab,
                                                     krb5_keytab_entry **));
 krb5_error_code krb5_ktfileint_write_entry PROTOTYPE((krb5_keytab,
                                                      krb5_keytab_entry *));
+/* and back to normal... */
+#include <krb5/narrow.h>
 
 #endif /* KRB5_KTFILE__ */
index 5ac5411d9fd277cb61a972f416655b3cd7520c73..9fb100a8f794861f18ea6d6d72836e32da59aebe 100644 (file)
@@ -45,6 +45,15 @@ static char rcsid_rd_req_c[] =
  returns system errors, encryption errors, replay errors
  */
 
+/* widen prototypes, if needed */
+#include <krb5/widen.h>
+typedef krb5_error_code (*rdreq_key_proc) PROTOTYPE((krb5_pointer, 
+                                                    krb5_principal,
+                                                    krb5_kvno,
+                                                    krb5_keyblock **));
+/* and back to normal... */
+#include <krb5/narrow.h>
+
 krb5_error_code
 krb5_rd_req(inbuf, server, sender_addr, fetchfrom, keyproc, keyprocarg,
            rcache, authdat)
@@ -52,10 +61,7 @@ const krb5_data *inbuf;
 krb5_const_principal server;
 const krb5_address *sender_addr;
 krb5_const_pointer fetchfrom;
-krb5_error_code (*keyproc) PROTOTYPE((krb5_pointer, 
-                                     krb5_principal,
-                                     krb5_kvno,
-                                     krb5_keyblock **));
+rdreq_key_proc keyproc;
 krb5_pointer keyprocarg;
 krb5_rcache rcache;
 krb5_tkt_authent *authdat;
index 9592daf0fb057c31a451b82dbf0e544f4ace4a85..40f1a9a24e7fc96f922cb709355db21bacb68458 100644 (file)
@@ -49,8 +49,18 @@ static char rcsid_rd_req_dec_c[] =
  returns system errors, encryption errors, replay errors
  */
 
+/* widen prototypes, if needed */
+#include <krb5/widen.h>
+
 static krb5_error_code decrypt_authenticator PROTOTYPE((const krb5_ap_req *,
                                                        krb5_authenticator **));
+typedef krb5_error_code (*rdreq_key_proc) PROTOTYPE((krb5_pointer, 
+                                                    krb5_principal,
+                                                    krb5_kvno,
+                                                    krb5_keyblock **));
+/* and back to normal... */
+#include <krb5/narrow.h>
+
 extern krb5_deltat krb5_clockskew;
 #define in_clock_skew(date) (abs((date)-currenttime) < krb5_clockskew)
 
@@ -61,10 +71,7 @@ const krb5_ap_req *req;
 krb5_const_principal server;
 const krb5_address *sender_addr;
 krb5_const_pointer fetchfrom;
-krb5_error_code (*keyproc) PROTOTYPE((krb5_pointer,
-                                     krb5_principal,
-                                     krb5_kvno,
-                                     krb5_keyblock **));
+rdreq_key_proc keyproc;
 krb5_pointer keyprocarg;
 krb5_rcache rcache;
 krb5_tkt_authent *tktauthent;