File tree Expand file tree Collapse file tree 1 file changed +4
-0
lines changed
src/backend/access/transam Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -1210,13 +1210,15 @@ ReadTwoPhaseFile(TransactionId xid, bool give_warnings)
1210
1210
stat .st_size > MaxAllocSize )
1211
1211
{
1212
1212
CloseTransientFile (fd );
1213
+ fprintf (stderr , "wrong size of two-phase file \"%s\"" , path );
1213
1214
return NULL ;
1214
1215
}
1215
1216
1216
1217
crc_offset = stat .st_size - sizeof (pg_crc32c );
1217
1218
if (crc_offset != MAXALIGN (crc_offset ))
1218
1219
{
1219
1220
CloseTransientFile (fd );
1221
+ fprintf (stderr , "wrong crc offset in two-phase file \"%s\"" , path );
1220
1222
return NULL ;
1221
1223
}
1222
1224
@@ -1243,6 +1245,7 @@ ReadTwoPhaseFile(TransactionId xid, bool give_warnings)
1243
1245
if (hdr -> magic != TWOPHASE_MAGIC || hdr -> total_len != stat .st_size )
1244
1246
{
1245
1247
pfree (buf );
1248
+ fprintf (stderr , "muggle two-phase file \"%s\": no magic" , path );
1246
1249
return NULL ;
1247
1250
}
1248
1251
@@ -1255,6 +1258,7 @@ ReadTwoPhaseFile(TransactionId xid, bool give_warnings)
1255
1258
if (!EQ_CRC32C (calc_crc , file_crc ))
1256
1259
{
1257
1260
pfree (buf );
1261
+ fprintf (stderr , "wrong crc32 in two-phase file \"%s\"" , path );
1258
1262
return NULL ;
1259
1263
}
1260
1264
You can’t perform that action at this time.
0 commit comments