forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit0fa6884
committed
Fix sign-compare warnings in pg_iovec.h.
The code in question (pg_preadv() and pg_pwritev()) has been aroundfor a while, but commit15c9ac3 moved it to a header file. Ifthird-party code that includes this header file is built with-Wsign-compare on a system without preadv() or pwritev(), warningsensue. This commit fixes said warnings by casting the result ofpg_pread()/pg_pwrite() to size_t, which should be safe because wewill have already checked for a negative value.Author: Wolfgang WaltherDiscussion:https://postgr.es/m/16989737-1aa8-48fd-8dfe-b7ada06509ab%40technowledgy.deBackpatch-through: 171 parentcaca6d8 commit0fa6884
1 file changed
+2
-2
lines changedLines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
68 | 68 |
| |
69 | 69 |
| |
70 | 70 |
| |
71 |
| - | |
| 71 | + | |
72 | 72 |
| |
73 | 73 |
| |
74 | 74 |
| |
| |||
107 | 107 |
| |
108 | 108 |
| |
109 | 109 |
| |
110 |
| - | |
| 110 | + | |
111 | 111 |
| |
112 | 112 |
| |
113 | 113 |
| |
|
0 commit comments
Comments
(0)