Changed SilcAskPasshrase and SilcGetAuthMet callbacks to return
authorPekka Riikonen <priikone@silcnet.org>
Sat, 19 May 2007 12:02:02 +0000 (12:02 +0000)
committerPekka Riikonen <priikone@silcnet.org>
Sat, 19 May 2007 12:02:02 +0000 (12:02 +0000)
data as const.

apps/irssi/src/silc/core/client_ops.c
lib/silcclient/command.c
lib/silcclient/silcclient.h

index 4ac23150b16fc2c0c84d842ac5761b66969e321a..2731d62ee35b21b4e721293eb9a5dda1e504afa7 100644 (file)
@@ -2683,7 +2683,7 @@ typedef struct {
   void *context;
 } *GetAuthMethod;
 
-static void silc_get_auth_ask_passphrase(unsigned char *passphrase,
+static void silc_get_auth_ask_passphrase(const unsigned char *passphrase,
                                         SilcUInt32 passphrase_len,
                                         void *context)
 {
index f7fd114af9e53d24f93099f03c5629d368df605d..0f66b97ad2ddeef002fd86c0ff7ccedbcbedb1df 100644 (file)
@@ -2199,7 +2199,7 @@ typedef struct {
 
 /* Ask passphrase callback */
 
-static void silc_client_command_oper_cb(unsigned char *data,
+static void silc_client_command_oper_cb(const unsigned char *data,
                                        SilcUInt32 data_len, void *context)
 {
   SilcClientCommandContext cmd = context;
index 536f3ee915a21e3130e5f6b81464cd397057032f..c67157e600270ecb418cfe31888872c3df23547f 100644 (file)
@@ -401,7 +401,7 @@ struct SilcChannelPrivateKeyStruct {
  *
  * SYNOPSIS
  *
- *    typedef void (*SilcAskPassphrase)(unsigned char *passphrase,
+ *    typedef void (*SilcAskPassphrase)(const unsigned char *passphrase,
  *                                     SilcUInt32 passphrase_len,
  *                                     void *context);
  *
@@ -414,7 +414,7 @@ struct SilcChannelPrivateKeyStruct {
  *    encoded, and if it is not then library will attempt to encode it.
  *
  ***/
-typedef void (*SilcAskPassphrase)(unsigned char *passphrase,
+typedef void (*SilcAskPassphrase)(const unsigned char *passphrase,
                                  SilcUInt32 passphrase_len,
                                  void *context);
 
@@ -439,7 +439,7 @@ typedef void (*SilcVerifyPublicKey)(SilcBool success, void *context);
  *
  *    typedef void (*SilcGetAuthMeth)(SilcBool success,
  *                                    SilcAuthMethod auth_meth,
- *                                    void *auth, SilcUInt32 auth_len,
+ *                                    const void *auth, SilcUInt32 auth_len,
  *                                    void *context);
  *
  * DESCRIPTION
@@ -461,7 +461,7 @@ typedef void (*SilcVerifyPublicKey)(SilcBool success, void *context);
  *
  ***/
 typedef void (*SilcGetAuthMeth)(SilcAuthMethod auth_meth,
-                               void *auth, SilcUInt32 auth_len,
+                               const void *auth, SilcUInt32 auth_len,
                                void *context);
 
 /****d* silcclient/SilcClientAPI/SilcClientMessageType