Skip to content

Commit

Permalink
Remove extraneous NULs after newlines in exported FreeOTP files
Browse files Browse the repository at this point in the history
  • Loading branch information
hubnut committed Feb 11, 2024
1 parent 81b2de8 commit d2efc10
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/common/freeotp.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export_freeotpplus (const gchar *export_path,
if (err == NULL) {
json_array_foreach (json_db_data, index, db_obj) {
gchar *uri = get_otpauth_uri (NULL, db_obj);
if (g_output_stream_write (G_OUTPUT_STREAM(out_stream), uri, g_utf8_strlen (uri, -1) + 1, NULL, &err) == -1) {
if (g_output_stream_write (G_OUTPUT_STREAM(out_stream), uri, g_utf8_strlen (uri, -1), NULL, &err) == -1) {
g_set_error (&err, generic_error_gquark (), GENERIC_ERRCODE, "couldn't dump json data to file");
}
g_free (uri);
Expand Down

0 comments on commit d2efc10

Please sign in to comment.