GNUnet  0.11.x
Data Structures | Functions
pq.h File Reference

shared internal data structures of libgnunetpq More...

#include "gnunet_util_lib.h"
#include "gnunet_pq_lib.h"
Include dependency graph for pq.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  GNUNET_PQ_Context
 Handle to Postgres database. More...


void GNUNET_PQ_event_reconnect_ (struct GNUNET_PQ_Context *db, int fd)
 Internal API. More...

Detailed Description

shared internal data structures of libgnunetpq

Christian Grothoff

Definition in file pq.h.

Function Documentation

◆ GNUNET_PQ_event_reconnect_()

void GNUNET_PQ_event_reconnect_ ( struct GNUNET_PQ_Context db,
int  fd 

Internal API.

Reconnect should re-register notifications after a disconnect.

dbthe DB handle
fdsocket to listen on

Definition at line 383 of file pq_event.c.

385 {
387  "Change in PQ event FD to %d\n",
388  fd);
390  fd);
393  db);
394 }
static struct GNUNET_FS_DirectoryBuilder * db
Definition: gnunet-search.c:41
#define GNUNET_log(kind,...)
int GNUNET_CONTAINER_multishortmap_iterate(struct GNUNET_CONTAINER_MultiShortmap *map, GNUNET_CONTAINER_ShortmapIterator it, void *it_cls)
Iterate over all entries in the map.
static int register_notify(void *cls, const struct GNUNET_ShortHashCode *sh, void *value)
Re-subscribe to notifications after disconnect.
Definition: pq_event.c:368
static void scheduler_fd_cb(void *cls, int fd)
Function called when the Postgres FD changes and we need to update the scheduler event loop task.
Definition: pq_event.c:286

References db, GNUNET_CONTAINER_multishortmap_iterate(), GNUNET_ERROR_TYPE_INFO, GNUNET_log, register_notify(), and scheduler_fd_cb().

Referenced by GNUNET_PQ_reconnect().

Here is the call graph for this function:
Here is the caller graph for this function: