forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit3d0d3c0
committed
Cast to (void *) rather than (int *) when passing int64's to PQfn().
This is a possibly-vain effort to silence a Coverity warning aboutbogus endianness dependency. The code's fine, because it takes careof endianness issues for itself, but Coverity sees an int64 beingpassed to an int* argument and not unreasonably suspects something'swrong. I'm not sure if putting the void* cast in the way will shut itup; but it can't hurt and seems better from a documentation standpointanyway, since the pointer is not used as an int* in this code path.Just for a bit of additional safety, verify that the result lengthis 8 bytes as expected.Back-patch to 9.3 where the code in question was added.1 parent089e5ab commit3d0d3c0
1 file changed
+5
-5
lines changedLines changed: 5 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
290 | 290 |
| |
291 | 291 |
| |
292 | 292 |
| |
293 |
| - | |
| 293 | + | |
294 | 294 |
| |
295 | 295 |
| |
296 | 296 |
| |
| |||
441 | 441 |
| |
442 | 442 |
| |
443 | 443 |
| |
444 |
| - | |
445 |
| - | |
| 444 | + | |
| 445 | + | |
446 | 446 |
| |
447 | 447 |
| |
448 | 448 |
| |
| |||
607 | 607 |
| |
608 | 608 |
| |
609 | 609 |
| |
610 |
| - | |
611 |
| - | |
| 610 | + | |
| 611 | + | |
612 | 612 |
| |
613 | 613 |
| |
614 | 614 |
| |
|
0 commit comments
Comments
(0)