[hipl-commit] [trunk] Rev 4631: Fix the issues introduced in rev 4629.

  • From: Mircea Gherzan <mircea.gherzan@xxxxxxxxxxxxxx>
  • To: hipl-commit@xxxxxxxxxxxxx
  • Date: Sun, 30 May 2010 21:11:05 +0300

Committer: Mircea Gherzan <mircea.gherzan@xxxxxxxxxxxxxx>
Date: 30/05/2010 at 21:11:04
Revision: 4631
Revision-id: mircea.gherzan@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Branch nick: trunk

Log:
  Fix the issues introduced in rev 4629.

Modified:
  M  firewall/firewall.c
  M  hipd/init.c
  M  hipd/input.c
  M  lib/core/conf.c
  M  lib/core/debug.c
  M  lib/core/debug.h
  M  lib/core/hostid.c

=== modified file 'firewall/firewall.c'
--- firewall/firewall.c 2010-05-26 10:28:47 +0000
+++ firewall/firewall.c 2010-05-30 18:10:17 +0000
@@ -2077,7 +2077,7 @@
     }
 
     if (limit_capabilities) {
-        HIP_IFEL(hip_set_lowcapability(0), -1, "Failed to reduce priviledges");
+        HIP_IFEL(hip_set_lowcapability(), -1, "Failed to reduce priviledges");
     }
 
     highest_descriptor = maxof(3, hip_fw_async_sock, h4->fd, h6->fd);

=== modified file 'hipd/init.c'
--- hipd/init.c 2010-05-30 15:53:09 +0000
+++ hipd/init.c 2010-05-30 18:10:17 +0000
@@ -1136,7 +1136,7 @@
 #endif
 
     if (flags & HIPD_START_LOWCAP) {
-        HIP_IFEL(hip_set_lowcapability(0), -1, "Failed to set capabilities\n");
+        HIP_IFEL(hip_set_lowcapability(), -1, "Failed to set capabilities\n");
     }
 
     hip_firewall_sock_lsi_fd = hip_user_sock;

=== modified file 'hipd/input.c'
--- hipd/input.c        2010-05-30 16:10:28 +0000
+++ hipd/input.c        2010-05-30 18:10:17 +0000
@@ -1490,7 +1490,7 @@
              "HIP_TRANSFORM parameter missing from I2 packet. Dropping\n");
 
     HIP_IFEL(!(ctx->hadb_entry->hip_transform =
-                            hip_get_param_transform_suite_id(hip_transform, 
0)),
+                            hip_get_param_transform_suite_id(hip_transform)),
              -EPROTO,
              "Bad HIP transform. Dropping the I2 packet.\n");
 

=== modified file 'lib/core/conf.c'
--- lib/core/conf.c     2010-05-30 17:04:14 +0000
+++ lib/core/conf.c     2010-05-30 18:10:17 +0000
@@ -176,7 +176,7 @@
  *                  should block for a response from hipd
  * @return zero for success and negative on error
  */
-static int hip_get_hits(hip_common_t *msg, const char *opt, int send_only)
+static int hip_get_hits(hip_common_t *msg, const char *opt, int optc, int 
send_only)
 {
     int err                              = 0;
     struct hip_tlv_common *current_param = NULL;
@@ -286,6 +286,7 @@
  * @note this does not flush the host identities from disk
  */
 static int hip_conf_handle_hi_del_all(hip_common_t *msg,
+                                      int action,
                                       const char *opt[],
                                       int optc,
                                       int send_only)

=== modified file 'lib/core/debug.c'
--- lib/core/debug.c    2010-05-30 17:04:14 +0000
+++ lib/core/debug.c    2010-05-30 18:10:17 +0000
@@ -56,6 +56,7 @@
 #include <sys/socket.h>
 #include <sys/types.h>
 
+#include "lib/core/common_defines.h"
 #include "lib/tool/lutil.h"
 #include "builder.h"
 #include "ife.h"
@@ -631,20 +632,21 @@
 }
 
 /**
- * print a socket address structure
+ * Print a socket address structure.
  *
- * @param line the line of the debug call in the source file
- * @param function the name of function where the debug call is located
- * @param prefix the prefix string will printed before the sockaddr
- * @param family the family of the sockaddr
- * @param sockaddr pointer to the sockaddr to be printed
+ * @param file      source file.
+ * @param line      the line of the debug call in the source file
+ * @param function  the name of function where the debug call is located
+ * @param prefix    the prefix string will printed before the sockaddr
+ * @param family    the family of the sockaddr
+ * @param sockaddr  pointer to the sockaddr to be printed
  *
  * @note Do not call this function from the outside of the debug module, use 
the
  * HIP_DEBUG_SOCKADDR macro instead.
  * @note Currently this function supports only INET and INET6 addresses.
  */
-void hip_print_sockaddr(int line, const char *function, const char *prefix,
-                        const struct sockaddr *sockaddr)
+void hip_print_sockaddr(UNUSED const char *file, int line, const char 
*function,
+                        const char *prefix, const struct sockaddr *sockaddr)
 {
     const char *default_str = "<unknown>";
     int maxlen;

=== modified file 'lib/core/debug.h'
--- lib/core/debug.h    2010-05-30 17:04:14 +0000
+++ lib/core/debug.h    2010-05-30 18:10:17 +0000
@@ -356,7 +356,8 @@
                       const char *prefix,
                       const void *str,
                       int len);
-void hip_print_sockaddr(int line,
+void hip_print_sockaddr(const char *file,
+                        int line,
                         const char *function,
                         const char *prefix,
                         const struct sockaddr *sockaddr);

=== modified file 'lib/core/hostid.c'
--- lib/core/hostid.c   2010-05-23 11:33:26 +0000
+++ lib/core/hostid.c   2010-05-30 18:10:17 +0000
@@ -789,8 +789,7 @@
                 goto out_err;
             }
 
-            if ((err = hip_private_dsa_to_hit(dsa_key, dsa_key_rr,
-                                              HIP_HIT_TYPE_HASH100, 
&dsa_lhi.hit))) {
+            if ((err = hip_private_dsa_to_hit(dsa_key, &dsa_lhi.hit))) {
                 HIP_ERROR("Conversion from DSA to HIT failed\n");
                 goto out_err;
             }
@@ -805,8 +804,7 @@
 
             HIP_DEBUG_HIT("DSA HIT", &dsa_lhi.hit);
 
-            if ((err = hip_private_dsa_to_hit(dsa_pub_key, dsa_pub_key_rr,
-                                              HIP_HIT_TYPE_HASH100, 
&dsa_pub_lhi.hit))) {
+            if ((err = hip_private_dsa_to_hit(dsa_pub_key, &dsa_pub_lhi.hit))) 
{
                 HIP_ERROR("Conversion from DSA to HIT failed\n");
                 goto out_err;
             }
@@ -832,8 +830,7 @@
                 goto out_err;
             }
 
-            if ((err = hip_private_rsa_to_hit(rsa_key, rsa_key_rr,
-                                              HIP_HIT_TYPE_HASH100,  
&rsa_lhi.hit))) {
+            if ((err = hip_private_rsa_to_hit(rsa_key, &rsa_lhi.hit))) {
                 HIP_ERROR("Conversion from RSA to HIT failed\n");
                 goto out_err;
             }
@@ -853,8 +850,7 @@
                 goto out_err;
             }
 
-            if ((err = hip_private_rsa_to_hit(rsa_pub_key, rsa_pub_key_rr,
-                                              HIP_HIT_TYPE_HASH100, 
&rsa_pub_lhi.hit))) {
+            if ((err = hip_private_rsa_to_hit(rsa_pub_key, &rsa_pub_lhi.hit))) 
{
                 HIP_ERROR("Conversion from RSA to HIT failed\n");
                 goto out_err;
             }

Other related posts:

  • » [hipl-commit] [trunk] Rev 4631: Fix the issues introduced in rev 4629. - Mircea Gherzan