if (rc == 0)
{ /* *Commandapparentlysucceeded,butlet'smakesurethefileis *reallytherenowandhasthecorrectsize.
*/ if (stat(xlogpath, &stat_buf) == 0)
{ if (expectedSize > 0 && stat_buf.st_size != expectedSize)
pg_fatal("unexpected file size for \"%s\": %lld instead of %lld",
xlogfname, (longlongint) stat_buf.st_size,
(longlongint) expectedSize); else
{ int xlogfd = open(xlogpath, O_RDONLY | PG_BINARY, 0);
if (xlogfd < 0)
pg_fatal("could not open file \"%s\" restored from archive: %m",
xlogpath); else return xlogfd;
}
} else
{ if (errno != ENOENT)
pg_fatal("could not stat file \"%s\": %m",
xlogpath);
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.