diff options
author | Christian Grothoff <christian@grothoff.org> | 2010-12-19 18:22:20 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2010-12-19 18:22:20 +0000 |
commit | 15de71a29f22caee6b15956b162e1e5a0f5f4f3e (patch) | |
tree | 9118b73d3253af3cec9fff3a5599dca966a02ec4 /src/datastore/test_datastore_api.c | |
parent | fcfd24ac2947d5129307614e85f6fbba45104530 (diff) | |
download | gnunet-15de71a29f22caee6b15956b162e1e5a0f5f4f3e.tar.gz gnunet-15de71a29f22caee6b15956b162e1e5a0f5f4f3e.zip |
LRN patch from SVN 1630
Diffstat (limited to 'src/datastore/test_datastore_api.c')
-rw-r--r-- | src/datastore/test_datastore_api.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/datastore/test_datastore_api.c b/src/datastore/test_datastore_api.c index 06abc0c0f..2edc9a6ec 100644 --- a/src/datastore/test_datastore_api.c +++ b/src/datastore/test_datastore_api.c | |||
@@ -678,13 +678,17 @@ int | |||
678 | main (int argc, char *argv[]) | 678 | main (int argc, char *argv[]) |
679 | { | 679 | { |
680 | int ret; | 680 | int ret; |
681 | const char *pos; | 681 | char *pos; |
682 | char dir_name[128]; | 682 | char dir_name[128]; |
683 | 683 | ||
684 | /* determine name of plugin to use */ | 684 | /* determine name of plugin to use */ |
685 | plugin_name = argv[0]; | 685 | plugin_name = argv[0]; |
686 | while (NULL != (pos = strstr(plugin_name, "_"))) | 686 | while (NULL != (pos = strstr(plugin_name, "_"))) |
687 | plugin_name = pos+1; | 687 | plugin_name = pos+1; |
688 | if (NULL != (pos = strstr(plugin_name, "."))) | ||
689 | pos[0] = 0; | ||
690 | else | ||
691 | pos = (char *) plugin_name; | ||
688 | 692 | ||
689 | GNUNET_snprintf (dir_name, | 693 | GNUNET_snprintf (dir_name, |
690 | sizeof (dir_name), | 694 | sizeof (dir_name), |
@@ -699,6 +703,8 @@ main (int argc, char *argv[]) | |||
699 | #endif | 703 | #endif |
700 | NULL); | 704 | NULL); |
701 | ret = check (); | 705 | ret = check (); |
706 | if (pos != plugin_name) | ||
707 | pos[0] = '.'; | ||
702 | GNUNET_DISK_directory_remove (dir_name); | 708 | GNUNET_DISK_directory_remove (dir_name); |
703 | return ret; | 709 | return ret; |
704 | } | 710 | } |