aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-knxip_decrypt.c
diff options
context:
space:
mode:
authorJoão Valverde <j@v6e.pt>2021-12-17 20:05:19 +0000
committerJoão Valverde <j@v6e.pt>2021-12-19 20:25:11 +0000
commit22ee2764a7753c29133abebe83ba3c659f457b3d (patch)
tree3e75d8be1100d0f2f69687e02879a684cf48796f /epan/dissectors/packet-knxip_decrypt.c
parentfe5248717faa1c99a4d0c761fa8da63afffc5d3f (diff)
Replace g_snprintf() with snprintf() (dissectors)
Use macros from inttypes.h with format strings.
Diffstat (limited to 'epan/dissectors/packet-knxip_decrypt.c')
-rw-r--r--epan/dissectors/packet-knxip_decrypt.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-knxip_decrypt.c b/epan/dissectors/packet-knxip_decrypt.c
index 4eaba15a04..c881233eee 100644
--- a/epan/dissectors/packet-knxip_decrypt.c
+++ b/epan/dissectors/packet-knxip_decrypt.c
@@ -297,7 +297,7 @@ static void decrypt_key( guint8 key[] _U_, guint8 password_hash[] _U_, guint8 cr
static void decode_and_decrypt_key( guint8 key[ BASE64_KNX_KEY_LENGTH + 1 ], const gchar* text, guint8 password_hash[], guint8 created_hash[] )
{
gsize out_len;
- g_snprintf( (gchar*) key, BASE64_KNX_KEY_LENGTH + 1, "%s", text );
+ snprintf( (gchar*) key, BASE64_KNX_KEY_LENGTH + 1, "%s", text );
g_base64_decode_inplace( (gchar*) key, &out_len );
decrypt_key( key, password_hash, created_hash );
}
@@ -503,7 +503,7 @@ static void add_ia_seq( guint16 ia, const gchar* text, FILE* f2 )
if( f2 )
{
- fprintf( f2, "IA %u.%u.%u SeqNr %" G_GINT64_MODIFIER "u\n", (ia >> 12) & 0xF, (ia >> 8) & 0xF, ia & 0xFF, seq );
+ fprintf( f2, "IA %u.%u.%u SeqNr %" PRIu64 "\n", (ia >> 12) & 0xF, (ia >> 8) & 0xF, ia & 0xFF, seq );
}
ia_seq = wmem_new(wmem_epan_scope(), struct knx_keyring_ia_seqs);
@@ -637,7 +637,7 @@ void read_knx_keyring_xml_file( const gchar* key_file, const gchar* password, co
if( !tag_name_done ) // tag name
{
- g_snprintf( tag_name, sizeof tag_name, "%s", name );
+ snprintf( tag_name, sizeof tag_name, "%s", name );
*name = '\0';
tag_name_done = 1;
}