lab.nexedi.com will be down from Thursday, 20 March 2025, 07:30:00 UTC for a duration of approximately 2 hours

Commit 37317e4f authored by Michael Tremer's avatar Michael Tremer

Enable debug logging for all tests

Signed-off-by: default avatarMichael Tremer <michael.tremer@ipfire.org>
parent 3b4f1368
......@@ -17,6 +17,7 @@
#include <errno.h>
#include <stdlib.h>
#include <string.h>
#include <syslog.h>
#include <loc/libloc.h>
#include <loc/database.h>
......@@ -32,6 +33,9 @@ int main(int argc, char** argv) {
if (err < 0)
exit(EXIT_FAILURE);
// Enable debug logging
loc_set_log_priority(ctx, LOG_DEBUG);
// Create a database
struct loc_writer* writer;
err = loc_writer_new(ctx, &writer, NULL, NULL);
......
......@@ -19,6 +19,7 @@
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
#include <syslog.h>
#include <loc/libloc.h>
#include <loc/country.h>
......@@ -47,6 +48,9 @@ int main(int argc, char** argv) {
if (err < 0)
exit(EXIT_FAILURE);
// Enable debug logging
loc_set_log_priority(ctx, LOG_DEBUG);
// Create a database
struct loc_writer* writer;
err = loc_writer_new(ctx, &writer, NULL, NULL);
......
......@@ -22,6 +22,7 @@
#include <ctype.h>
#include <errno.h>
#include <unistd.h>
#include <syslog.h>
#include <loc/libloc.h>
#include <loc/database.h>
......@@ -66,6 +67,9 @@ int main(int argc, char** argv) {
if (err < 0)
exit(EXIT_FAILURE);
// Enable debug logging
loc_set_log_priority(ctx, LOG_DEBUG);
// Try opening an empty file
err = attempt_to_open(ctx, "/dev/null");
if (err == 0)
......
......@@ -22,6 +22,7 @@
#include <ctype.h>
#include <errno.h>
#include <unistd.h>
#include <syslog.h>
#include <loc/libloc.h>
......@@ -32,6 +33,9 @@ int main(int argc, char** argv) {
if (err < 0)
exit(EXIT_FAILURE);
// Enable debug logging
loc_set_log_priority(ctx, LOG_DEBUG);
printf("version %s\n", VERSION);
loc_unref(ctx);
......
......@@ -19,6 +19,7 @@
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
#include <syslog.h>
#include <loc/libloc.h>
#include <loc/database.h>
......@@ -33,6 +34,9 @@ int main(int argc, char** argv) {
if (err < 0)
exit(EXIT_FAILURE);
// Enable debug logging
loc_set_log_priority(ctx, LOG_DEBUG);
struct loc_network_tree* tree;
err = loc_network_tree_new(ctx, &tree);
if (err) {
......
......@@ -22,6 +22,7 @@
#include <ctype.h>
#include <errno.h>
#include <unistd.h>
#include <syslog.h>
#include <loc/libloc.h>
#include <loc/database.h>
......@@ -55,6 +56,9 @@ int main(int argc, char** argv) {
if (err < 0)
exit(EXIT_FAILURE);
// Enable debug logging
loc_set_log_priority(ctx, LOG_DEBUG);
// Create an empty database
struct loc_writer* writer;
err = loc_writer_new(ctx, &writer, private_key1, private_key2);
......
......@@ -24,6 +24,7 @@
#include <errno.h>
#include <unistd.h>
#include <time.h>
#include <syslog.h>
#include <loc/libloc.h>
#include <loc/stringpool.h>
......@@ -54,6 +55,9 @@ int main(int argc, char** argv) {
if (err < 0)
exit(EXIT_FAILURE);
// Enable debug logging
loc_set_log_priority(ctx, LOG_DEBUG);
// Create the stringpool
struct loc_stringpool* pool;
err = loc_stringpool_new(ctx, &pool);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment