struct GNUNET_FS_Uri *ret;
char *emsg;
- if (NULL != GNUNET_FS_uri_parse ("gnunet://fs/ksk/++", &emsg))
- ABORT ();
+ if (NULL != (ret = GNUNET_FS_uri_parse ("gnunet://fs/ksk/++", &emsg)))
+ {
+ GNUNET_FS_uri_destroy (ret);
+ ABORT ();
+ }
GNUNET_free (emsg);
ret = GNUNET_FS_uri_parse ("gnunet://fs/ksk/foo+bar", &emsg);
if (ret == NULL)
baseURI =
GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H000004400000.42", &emsg);
GNUNET_assert (baseURI != NULL);
+ GNUNET_assert (emsg == NULL);
cfg = GNUNET_CONFIGURATION_create ();
if (GNUNET_OK !=
GNUNET_CONFIGURATION_parse (cfg, "test_fs_uri_data.conf"))
{
fprintf (stderr, "Failed to parse configuration file\n");
+ GNUNET_FS_uri_destroy (baseURI);
GNUNET_CONFIGURATION_destroy (cfg);
return 1;
}
GNUNET_break (0);
GNUNET_FS_uri_destroy (uri);
GNUNET_CONFIGURATION_destroy (cfg);
+ GNUNET_free (emsg);
return 1;
}
+ GNUNET_assert (NULL == emsg);
if (GNUNET_YES != GNUNET_FS_uri_test_equal (uri, uri2))
{
GNUNET_break (0);
char *emsg;
if (NULL !=
- GNUNET_FS_uri_parse ("gnunet://fs/sks/D1KJS9H2A82Q65VKQ0ML3RFU6U1D3VUK", &emsg))
- ABORT ();
+ (ret = GNUNET_FS_uri_parse ("gnunet://fs/sks/D1KJS9H2A82Q65VKQ0ML3RFU6U1D3VUK", &emsg)))
+ {
+ GNUNET_FS_uri_destroy (ret);
+ ABORT ();
+ }
GNUNET_free (emsg);
if (NULL !=
- GNUNET_FS_uri_parse ("gnunet://fs/sks/D1KJS9H2A82Q65VKQ0ML3RFU6U1D3V/test", &emsg))
+ (ret = GNUNET_FS_uri_parse ("gnunet://fs/sks/D1KJS9H2A82Q65VKQ0ML3RFU6U1D3V/test", &emsg)))
+ {
+ GNUNET_FS_uri_destroy (ret);
ABORT ();
+ }
GNUNET_free (emsg);
- if (NULL != GNUNET_FS_uri_parse ("gnunet://fs/sks/test", &emsg))
- ABORT ();
+ if (NULL != (ret = GNUNET_FS_uri_parse ("gnunet://fs/sks/test", &emsg)))
+ {
+ GNUNET_FS_uri_destroy (ret);
+ ABORT ();
+ }
GNUNET_free (emsg);
ret =
GNUNET_FS_uri_parse ("gnunet://fs/sks/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820/test", &emsg);
char *emsg;
if (NULL !=
- GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H00000440000.42", &emsg))
- ABORT ();
+ (ret = GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H00000440000.42", &emsg)))
+ {
+ GNUNET_FS_uri_destroy (ret);
+ ABORT ();
+ }
GNUNET_free (emsg);
if (NULL !=
- GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H000004400000", &emsg))
- ABORT ();
+ (ret = GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H000004400000", &emsg)))
+ {
+ GNUNET_FS_uri_destroy (ret);
+ ABORT ();
+ }
GNUNET_free (emsg);
if (NULL !=
- GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H000004400000.FGH", &emsg))
- ABORT ();
+ (ret = GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H000004400000.FGH", &emsg)))
+ {
+ GNUNET_FS_uri_destroy (ret);
+ ABORT ();
+ }
GNUNET_free (emsg);
ret =
GNUNET_FS_uri_parse ("gnunet://fs/chk/C282GG70GKK41O4551011DO413KFBVTVMQG1OG30I0K4045N0G41HAPB82G680A02JRVVFO8URVRU2F159011DO41000000022RG820.RNVVVVOOLCLK065B5D04HTNVNSIB2AI022RG8200HSLK1CO1000ATQ98824DMA2032LIMG50CG0K057NVUVG200000H000004400000.42", &emsg);