PostGIS  2.1.10dev-r@@SVN_REVISION@@
static int pgui_copy_end ( const int  rollback)
static

Definition at line 405 of file shp2pgsql-gui.c.

References pg_connection, and pgui_logf().

Referenced by pgui_action_import().

406 {
407  char *errmsg = NULL;
408 
409  /* We need a connection to do anything. */
410  if ( ! pg_connection ) return 0;
411 
412  if ( rollback ) errmsg = "Roll back the copy.";
413 
414  /* Did something unexpected happen? */
415  if ( PQputCopyEnd(pg_connection, errmsg) < 0 )
416  {
417  /* Log errors and return failure. */
418  pgui_logf("Failed in pgui_copy_end(): %s", PQerrorMessage(pg_connection));
419  return 0;
420  }
421 
422  return 1;
423 }
static void pgui_logf(const char *fmt,...)
static PGconn * pg_connection

Here is the call graph for this function:

Here is the caller graph for this function: