diff options
author | Gabor X Toth <*@tg-x.net> | 2013-09-16 16:05:58 +0000 |
---|---|---|
committer | Gabor X Toth <*@tg-x.net> | 2013-09-16 16:05:58 +0000 |
commit | 6ea3d4aca0abfd35bfba6759c1655cbac057b68f (patch) | |
tree | 751b7da8be68b20cf6bbe03ec7540f9dd4cfc44b /src/psycstore | |
parent | 31e0571c997c8adbeaff9d48550290d7e7379434 (diff) | |
download | gnunet-6ea3d4aca0abfd35bfba6759c1655cbac057b68f.tar.gz gnunet-6ea3d4aca0abfd35bfba6759c1655cbac057b68f.zip |
psyc service skeleton
Diffstat (limited to 'src/psycstore')
-rw-r--r-- | src/psycstore/gnunet-service-psycstore.c | 18 | ||||
-rw-r--r-- | src/psycstore/psycstore.h | 4 | ||||
-rw-r--r-- | src/psycstore/test_psycstore.c | 10 | ||||
-rw-r--r-- | src/psycstore/test_psycstore.conf | 3 |
4 files changed, 14 insertions, 21 deletions
diff --git a/src/psycstore/gnunet-service-psycstore.c b/src/psycstore/gnunet-service-psycstore.c index 8a21167e1..14945641f 100644 --- a/src/psycstore/gnunet-service-psycstore.c +++ b/src/psycstore/gnunet-service-psycstore.c | |||
@@ -23,11 +23,8 @@ | |||
23 | * @brief PSYCstore service | 23 | * @brief PSYCstore service |
24 | * @author Gabor X Toth | 24 | * @author Gabor X Toth |
25 | * @author Christian Grothoff | 25 | * @author Christian Grothoff |
26 | * | ||
27 | * The purpose of this service is to manage private keys that | ||
28 | * represent the various egos/pseudonyms/identities of a GNUnet user. | ||
29 | * | ||
30 | */ | 26 | */ |
27 | |||
31 | #include "platform.h" | 28 | #include "platform.h" |
32 | #include "gnunet_util_lib.h" | 29 | #include "gnunet_util_lib.h" |
33 | #include "gnunet_constants.h" | 30 | #include "gnunet_constants.h" |
@@ -666,15 +663,14 @@ handle_state_get_prefix (void *cls, | |||
666 | 663 | ||
667 | 664 | ||
668 | /** | 665 | /** |
669 | * Handle PSYCstore clients. | 666 | * Initialize the PSYCstore service. |
670 | * | 667 | * |
671 | * @param cls closure | 668 | * @param cls Closure. |
672 | * @param server the initialized server | 669 | * @param server The initialized server. |
673 | * @param c configuration to use | 670 | * @param c Configuration to use. |
674 | */ | 671 | */ |
675 | static void | 672 | static void |
676 | run (void *cls, | 673 | run (void *cls, struct GNUNET_SERVER_Handle *server, |
677 | struct GNUNET_SERVER_Handle *server, | ||
678 | const struct GNUNET_CONFIGURATION_Handle *c) | 674 | const struct GNUNET_CONFIGURATION_Handle *c) |
679 | { | 675 | { |
680 | static const struct GNUNET_SERVER_MessageHandler handlers[] = { | 676 | static const struct GNUNET_SERVER_MessageHandler handlers[] = { |
@@ -766,7 +762,7 @@ run (void *cls, | |||
766 | 762 | ||
767 | 763 | ||
768 | /** | 764 | /** |
769 | * The main function for the network size estimation service. | 765 | * The main function for the service. |
770 | * | 766 | * |
771 | * @param argc number of arguments from the command line | 767 | * @param argc number of arguments from the command line |
772 | * @param argv command line arguments | 768 | * @param argv command line arguments |
diff --git a/src/psycstore/psycstore.h b/src/psycstore/psycstore.h index 3a7a9feed..cc382a456 100644 --- a/src/psycstore/psycstore.h +++ b/src/psycstore/psycstore.h | |||
@@ -24,8 +24,8 @@ | |||
24 | * @author Gabor X Toth | 24 | * @author Gabor X Toth |
25 | */ | 25 | */ |
26 | 26 | ||
27 | #ifndef PSYCSTORE_H | 27 | #ifndef GNUNET_PSYCSTORE_H |
28 | #define PSYCSTORE_H | 28 | #define GNUNET_PSYCSTORE_H |
29 | 29 | ||
30 | #include "gnunet_common.h" | 30 | #include "gnunet_common.h" |
31 | 31 | ||
diff --git a/src/psycstore/test_psycstore.c b/src/psycstore/test_psycstore.c index 15eb2de30..cfda6819e 100644 --- a/src/psycstore/test_psycstore.c +++ b/src/psycstore/test_psycstore.c | |||
@@ -500,13 +500,13 @@ static void | |||
500 | run (void *cls, char *const *args, const char *cfgfile, | 500 | run (void *cls, char *const *args, const char *cfgfile, |
501 | const struct GNUNET_CONFIGURATION_Handle *cfg) | 501 | const struct GNUNET_CONFIGURATION_Handle *cfg) |
502 | #else | 502 | #else |
503 | run (void *cls, | 503 | run (void *cls, |
504 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 504 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
505 | struct GNUNET_TESTING_Peer *peer) | 505 | struct GNUNET_TESTING_Peer *peer) |
506 | #endif | 506 | #endif |
507 | { | 507 | { |
508 | end_badly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 508 | end_badly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, &end_badly, NULL); |
509 | &end_badly, NULL); | 509 | |
510 | h = GNUNET_PSYCSTORE_connect (cfg); | 510 | h = GNUNET_PSYCSTORE_connect (cfg); |
511 | GNUNET_assert (NULL != h); | 511 | GNUNET_assert (NULL != h); |
512 | 512 | ||
diff --git a/src/psycstore/test_psycstore.conf b/src/psycstore/test_psycstore.conf index 4c52d1ce0..a7d334617 100644 --- a/src/psycstore/test_psycstore.conf +++ b/src/psycstore/test_psycstore.conf | |||
@@ -1,7 +1,6 @@ | |||
1 | [arm] | 1 | [arm] |
2 | UNIXPATH = /tmp/test-gnunet-service-arm.sock | 2 | UNIXPATH = /tmp/test-gnunet-service-arm.sock |
3 | DEFAULTSERVICES = psycstore | 3 | DEFAULTSERVICES = psycstore |
4 | GLOBAL_POSTFIX = -L DEBUG | ||
5 | 4 | ||
6 | [psycstore] | 5 | [psycstore] |
7 | AUTOSTART = YES | 6 | AUTOSTART = YES |
@@ -11,8 +10,6 @@ UNIXPATH = /tmp/test-gnunet-service-psycstore.sock | |||
11 | UNIX_MATCH_UID = NO | 10 | UNIX_MATCH_UID = NO |
12 | UNIX_MATCH_GID = YES | 11 | UNIX_MATCH_GID = YES |
13 | DATABASE = sqlite | 12 | DATABASE = sqlite |
14 | OPTIONS = -L DEBUG | ||
15 | DEBUG = YES | ||
16 | 13 | ||
17 | [psycstore-sqlite] | 14 | [psycstore-sqlite] |
18 | FILENAME = $SERVICEHOME/psycstore/sqlite_test.db | 15 | FILENAME = $SERVICEHOME/psycstore/sqlite_test.db |