Clean up after merge with upstream.

This commit is contained in:
Petter Reinholdtsen 2013-10-21 21:29:35 +02:00
commit 8a19411c26
6 changed files with 17 additions and 13 deletions

View File

@ -2614,9 +2614,9 @@ struct cli_schema command_line_options[]={
"Return identity(s) as URIs of own node, or of known routable peers, or all known peers"},
{app_id_pin, {"id", "enter", "pin", "<entry-pin>", NULL}, 0,
"Unlock any pin protected identities and enable routing packets to them"},
{app_revoke_pin, {"id", "revoke", "pin", "<entry-pin>", NULL}, 0,
{app_revoke_pin, {"id", "relinquish", "pin", "<entry-pin>", NULL}, 0,
"Unload any identities protected by this pin and drop all routes to them"},
{app_revoke_pin, {"id", "revoke", "sid", "<sid>", NULL}, 0,
{app_revoke_pin, {"id", "relinquish", "sid", "<sid>", NULL}, 0,
"Unload a specific identity and drop all routes to it"},
{app_route_print, {"route","print",NULL}, 0,
"Print the routing table"},

View File

@ -661,7 +661,7 @@ int _sqlite_vbind(struct __sourceloc __whence, int log_level, sqlite_retry_state
BIND_NULL(SID_T);
} else {
const char *sid_hex = alloca_tohex_sid_t(*sidp);
BIND_DEBUG(SID_T, sqlite3_bind_text, "%s,%d,SQLITE_TRANSIENT", sid_hex, SID_STRLEN);
BIND_DEBUG(SID_T, sqlite3_bind_text, "%s,%u,SQLITE_TRANSIENT", sid_hex, SID_STRLEN);
BIND_RETRY(sqlite3_bind_text, sid_hex, SID_STRLEN, SQLITE_TRANSIENT);
}
}
@ -673,7 +673,7 @@ int _sqlite_vbind(struct __sourceloc __whence, int log_level, sqlite_retry_state
BIND_NULL(RHIZOME_BID_T);
} else {
const char *bid_hex = alloca_tohex_rhizome_bid_t(*bidp);
BIND_DEBUG(RHIZOME_BID_T, sqlite3_bind_text, "%s,%d,SQLITE_TRANSIENT", bid_hex, RHIZOME_MANIFEST_ID_STRLEN);
BIND_DEBUG(RHIZOME_BID_T, sqlite3_bind_text, "%s,%u,SQLITE_TRANSIENT", bid_hex, RHIZOME_MANIFEST_ID_STRLEN);
BIND_RETRY(sqlite3_bind_text, bid_hex, RHIZOME_MANIFEST_ID_STRLEN, SQLITE_TRANSIENT);
}
}
@ -686,7 +686,7 @@ int _sqlite_vbind(struct __sourceloc __whence, int log_level, sqlite_retry_state
} else {
char hash_hex[RHIZOME_FILEHASH_STRLEN];
tohex(hash_hex, sizeof hash_hex, hashp->binary);
BIND_DEBUG(RHIZOME_FILEHASH_T, sqlite3_bind_text, "%s,%zd,SQLITE_TRANSIENT", hash_hex, sizeof hash_hex);
BIND_DEBUG(RHIZOME_FILEHASH_T, sqlite3_bind_text, "%s,%zu,SQLITE_TRANSIENT", hash_hex, sizeof hash_hex);
BIND_RETRY(sqlite3_bind_text, hash_hex, sizeof hash_hex, SQLITE_TRANSIENT);
}
}
@ -699,7 +699,7 @@ int _sqlite_vbind(struct __sourceloc __whence, int log_level, sqlite_retry_state
BIND_NULL(TOHEX);
} else {
const char *hex = alloca_tohex(binary, bytes);
BIND_DEBUG(TOHEX, sqlite3_bind_text, "%s,%d,SQLITE_TRANSIENT", hex, bytes * 2);
BIND_DEBUG(TOHEX, sqlite3_bind_text, "%s,%u,SQLITE_TRANSIENT", hex, bytes * 2);
BIND_RETRY(sqlite3_bind_text, hex, bytes * 2, SQLITE_TRANSIENT);
}
}
@ -713,7 +713,7 @@ int _sqlite_vbind(struct __sourceloc __whence, int log_level, sqlite_retry_state
unsigned bytes = strlen(text);
char upper[bytes + 1];
str_toupper_inplace(strcpy(upper, text));
BIND_DEBUG(TEXT_TOUPPER, sqlite3_bind_text, "%s,%d,SQLITE_TRANSIENT", alloca_toprint(-1, upper, bytes), bytes);
BIND_DEBUG(TEXT_TOUPPER, sqlite3_bind_text, "%s,%u,SQLITE_TRANSIENT", alloca_toprint(-1, upper, bytes), bytes);
BIND_RETRY(sqlite3_bind_text, upper, bytes, SQLITE_TRANSIENT);
}
}
@ -729,7 +729,7 @@ int _sqlite_vbind(struct __sourceloc __whence, int log_level, sqlite_retry_state
unsigned i;
for (i = 0; i != bytes; ++i)
upper[i] = toupper(text[i]);
BIND_DEBUG(TEXT_LEN_TOUPPER, sqlite3_bind_text, "%s,%d,SQLITE_TRANSIENT", alloca_toprint(-1, upper, bytes), bytes);
BIND_DEBUG(TEXT_LEN_TOUPPER, sqlite3_bind_text, "%s,%u,SQLITE_TRANSIENT", alloca_toprint(-1, upper, bytes), bytes);
BIND_RETRY(sqlite3_bind_text, upper, bytes, SQLITE_TRANSIENT);
}
}

View File

@ -1195,9 +1195,8 @@ int link_received_packet(struct decode_context *context, int sender_seq, char un
// force an update when we start hearing a new neighbour link
if (link->link_timeout < now){
if (neighbour->next_neighbour_update > now + 10) {
if (neighbour->next_neighbour_update > now + 10)
neighbour->next_neighbour_update = now + 10;
}
}
link->link_timeout = now + (context->interface->destination->tick_ms *5);

View File

@ -235,13 +235,13 @@ test_KeyringEntryPinServer() {
assertStdoutGrep --fixed-strings "$ONE"
assertStdoutGrep --fixed-strings "$TWOA"
assertStdoutGrep --fixed-strings "$TWOB"
executeOk_servald id revoke pin 'one'
executeOk_servald id relinquish pin 'one'
executeOk_servald id self
assertStdoutLineCount == 3
assertStdoutGrep --fixed-strings "$SIDA"
assertStdoutGrep --fixed-strings "$TWOA"
assertStdoutGrep --fixed-strings "$TWOB"
executeOk_servald id revoke sid "$TWOB"
executeOk_servald id relinquish sid "$TWOB"
tfw_cat --stderr
executeOk_servald id self
assertStdoutLineCount == 2

View File

@ -164,7 +164,7 @@ test_unlock_ids() {
executeOk_servald id enter pin 'entry-pin'
wait_until has_link +B +A +A $SIDA $SIDX
set_instance +A
executeOk_servald id revoke pin 'entry-pin'
executeOk_servald id relinquish pin 'entry-pin'
set_instance +B
wait_until --timeout=30 sid_offline $SIDX
}

View File

@ -17,6 +17,11 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
if [ ! -e .git ]; then
echo "UNKNOWN-VERSION"
exit
fi
usage() {
echo "Usage: ${0##*/} [options]"'