Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf2a3cdb

Browse files
committed
Suppress bogus statistics when pgbench failed to complete any transactions.
Code added in 9.4 would attempt to divide by zero in such cases.Noted while testing fix for missing-pclose problem.
1 parent6c75384 commitf2a3cdb

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

‎contrib/pgbench/pgbench.c‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2299,6 +2299,10 @@ printResults(int ttype, int64 normal_xacts, int nclients,
22992299
normal_xacts);
23002300
}
23012301

2302+
/* Remaining stats are nonsensical if we failed to execute any xacts */
2303+
if (normal_xacts <=0)
2304+
return;
2305+
23022306
if (throttle_delay||progress)
23032307
{
23042308
/* compute and show latency average and standard deviation */

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp