* Obtain the location of ".my.cnf".
*
* @param cfg our configuration
+ * @param section the section
* @return NULL on error
*/
static char *
{
struct GNUNET_MYSQL_Context *mc;
- mc = GNUNET_malloc (sizeof (struct GNUNET_MYSQL_Context));
+ mc = GNUNET_new (struct GNUNET_MYSQL_Context);
mc->cfg = cfg;
mc->section = section;
mc->cnffile = get_my_cnf_path (cfg, section);
{
struct GNUNET_MYSQL_StatementHandle *sh;
- sh = GNUNET_malloc (sizeof (struct GNUNET_MYSQL_StatementHandle));
+ sh = GNUNET_new (struct GNUNET_MYSQL_StatementHandle);
sh->query = GNUNET_strdup (query);
GNUNET_CONTAINER_DLL_insert (mc->shead, mc->stail, sh);
return sh;