WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Affero General Public License for more details.
-
+
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+ SPDX-License-Identifier: AGPL3.0-or-later
*/
/*
* @file datacache/test_datacache_quota.c
if (h == NULL)
{
- FPRINTF (stderr,
+ fprintf (stderr,
"%s",
"Failed to initialize datacache. Database likely not setup, skipping test.\n");
return;
memset (&k, 0, sizeof (struct GNUNET_HashCode));
for (unsigned int i = 0; i < 10; i++)
{
- FPRINTF (stderr,
+ fprintf (stderr,
"%s",
".");
GNUNET_CRYPTO_hash (&k,
}
k = n;
}
- FPRINTF (stderr, "%s", "\n");
+ fprintf (stderr, "%s", "\n");
memset (&k, 0, sizeof (struct GNUNET_HashCode));
for (unsigned int i = 0; i < 10; i++)
{
- FPRINTF (stderr, "%s", ".");
+ fprintf (stderr, "%s", ".");
GNUNET_CRYPTO_hash (&k, sizeof (struct GNUNET_HashCode), &n);
if (i < 2)
ASSERT (0 == GNUNET_DATACACHE_get (h, &k, 1 + i, NULL, NULL));
ASSERT (0 < GNUNET_DATACACHE_get (h, &k, 1 + i, NULL, NULL));
k = n;
}
- FPRINTF (stderr, "%s", "\n");
+ fprintf (stderr, "%s", "\n");
GNUNET_DATACACHE_destroy (h);
return;
FAILURE:
main (int argc,
char *argv[])
{
- char cfg_name[128];
+ char cfg_name[PATH_MAX];
char *const xargv[] = {
"test-datacache-quota",
"-c",
&run,
NULL);
if (0 != ok)
- FPRINTF (stderr,
+ fprintf (stderr,
"Missed some testcases: %d\n",
ok);
return ok;