forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit9f34cae
committed
psql: Fix \watch when using interval values less than 1ms
Attempting to use an interval of time less than 1ms would cause \watchto hang. This was confusing, so let's change the logic so as aninterval lower than 1ms behaves the same as 0.Comments are added to mention that the internals of do_watch() hadbetter rely on "sleep_ms", the interval value in milliseconds. While onit, this commit adds a test to check the behavior of interval valuesless than 1ms.\watch hanging for interval values less than 1ms existed before6f9ee74, that has changed the code to support an interval value of0.Reported-by: Heikki LinnakangasAuthor: Andrey M. Borodin, Michael PaquierDiscussion:https://postgr.es/m/88445e0e-3156-4b9d-afae-9a1a7b1631f6@iki.fiBackpatch-through: 161 parent35a015a commit9f34cae
2 files changed
+16
-5
lines changedLines changed: 8 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
5359 | 5359 |
| |
5360 | 5360 |
| |
5361 | 5361 |
| |
| 5362 | + | |
| 5363 | + | |
| 5364 | + | |
| 5365 | + | |
5362 | 5366 |
| |
5363 | 5367 |
| |
5364 | 5368 |
| |
| |||
5484 | 5488 |
| |
5485 | 5489 |
| |
5486 | 5490 |
| |
5487 |
| - | |
| 5491 | + | |
5488 | 5492 |
| |
5489 | 5493 |
| |
5490 |
| - | |
| 5494 | + | |
5491 | 5495 |
| |
5492 | 5496 |
| |
5493 | 5497 |
| |
| |||
5508 | 5512 |
| |
5509 | 5513 |
| |
5510 | 5514 |
| |
5511 |
| - | |
| 5515 | + | |
| 5516 | + | |
5512 | 5517 |
| |
5513 | 5518 |
| |
5514 | 5519 |
| |
|
Lines changed: 8 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
352 | 352 |
| |
353 | 353 |
| |
354 | 354 |
| |
355 |
| - | |
356 |
| - | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
357 | 363 |
| |
358 | 364 |
| |
359 | 365 |
| |
|
0 commit comments
Comments
(0)