add: }  if(email_res) (*db_free_query)(db_handle,email_res);
context: static int vm_get_user_info( str* user,   /*[in]*/			     str* host,   /*[in]*/                             str* email   /*[out]*/){        db_res_t*       email_res=0;    	db_key_t keys[2];	db_val_t vals[2];	db_key_t cols[1];	keys[0] = user_column;	cols[0] = email_column;	VAL_TYPE(&(vals[0])) = DB_STR;	VAL_NULL(&(vals[0])) = 0;	VAL_STR(&(vals[0]))  = *user;	    #ifdef MULTI_DOMAIN	keys[1] = domain_column;	VAL_TYPE(&vals[1]) = DB_STR;	VAL_NULL(&vals[1]) = 0;	VAL_STR(&vals[1])  = *host;#endif	db_use_table(db_handle,subscriber_table);	if ((*db_query)(db_handle, keys, 0, vals, cols, #ifdef MULTI_DOMAIN			2, #else			1,#endif			1, 0, &email_res))	  {	    	    LOG(L_ERR,"ERROR: vm: db_query() failed.");	    goto error;	  }	    	if( (!email_res) || (email_res->n != 1) ){	  	  if(email_res)	    (*db_free_query)(db_handle,email_res);			  LOG( L_ERR,"ERROR: %s: no email for user '%.*s'",	       exports.name,	       user->len,user->s);	  goto error;	}	    	email->s = strdup(VAL_STRING(&(email_res->rows[0].values[0])));	email->len = strlen(email->s);	#ifdef MULTI_DOMAIN	domain->s = strdup(VAL_STRING(&(email_res->rows[0].values[1])));	domain->s = strlen(domain->s);#endif	    		return 0; error:	return -1;}