------------------------------------------------------------ revno: 6389 committer: Miika Komu <miika@xxxxxx> branch nick: hipl timestamp: Thu 2012-07-19 08:51:12 +0300 message: Fixed an initialization bug related to registration and HIPv2 Revision 6388 introduces HIPv2 support that works fine for regular application-initiated BEX. However, it did not work for daemon internal registration procedures because the version number was not initialized in the HADB. As a result, the responder complained about invalid version number in the I1. I have tested that this revision fixes this bug. modified: libhipl/registration.c -- lp:hipl https://code.launchpad.net/~hipl-core/hipl/trunk Your team HIPL core team is subscribed to branch lp:hipl. To unsubscribe from this branch go to https://code.launchpad.net/~hipl-core/hipl/trunk/+edit-subscription
=== modified file 'libhipl/registration.c' --- libhipl/registration.c 2012-05-12 10:21:32 +0000 +++ libhipl/registration.c 2012-07-19 05:51:12 +0000 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010 Aalto University and RWTH Aachen University. + * Copyright (c) 2010, 2012 Aalto University and RWTH Aachen University. * * Permission is hereby granted, free of charge, to any person * obtaining a copy of this software and associated documentation @@ -54,6 +54,7 @@ #include "netdev.h" #include "output.h" #include "registration.h" +#include "init.h" /** * Pending request lifetime. Pending requests are created when the requester @@ -1480,6 +1481,8 @@ "Did not find entry\n"); } + entry->hip_version = hip_get_default_version(); + reg_types = reg_req->reg_type; type_count = hip_get_param_contents_len(reg_req) - sizeof(reg_req->lifetime);