forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit4bc8c8d

Barry Lind
This patch fixes a bug reported by Graham Leggett (minfrin@sharp.fm).
The bug was that any insert or update would fail if the returned oid waslarger than a signed int. Since OIDs are unsigned int's it wasa bug that the code used a java signed int to deal with the values. The bugwould result in the error message: "Unable to fathom update count".While fixing the bug, it became apparent that other code made a similarassumption about OIDs being signed ints. Therefore some methods that returnedor took OIDs are arguements also needed to be changed.Since we are so close to the 7.2 release I have added new methods thatreturn longs and deprecated the old methods returning ints. Therefore allold code should still work without requiring a code change to cast from long to int. Also note that the methods below are PostgreSQL specific extensions tothe JDBC api are are not part of the spec from Sun, thus it is unlikely thatthey are used much or at all.The deprecated methods are: ResultSet.getInsertedOID() Statement.getInsertedOID() Serialize.store() Connection.putObject()and are replaced by: ResultSet.getLastOID() Statement.getLastOID() Serialize.storeObject() Connection.storeObject()All the deprecated methods returned int, while their replacements return longThis patch also fixes two comments in MD5Digest that the author Jeremy Wohlsubmitted.--Barry1 parent23b5ca9 commit4bc8c8d
File tree
14 files changed
+79
-45
lines changed- src/interfaces/jdbc
- example
- org/postgresql
- core
- jdbc1
- jdbc2
- util
14 files changed
+79
-45
lines changedLines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
6 | 6 |
| |
7 | 7 |
| |
8 | 8 |
| |
9 |
| - | |
| 9 | + | |
10 | 10 |
| |
11 | 11 |
| |
12 | 12 |
| |
| |||
89 | 89 |
| |
90 | 90 |
| |
91 | 91 |
| |
92 |
| - | |
| 92 | + | |
93 | 93 |
| |
94 | 94 |
| |
95 | 95 |
| |
|
Lines changed: 17 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
11 | 11 |
| |
12 | 12 |
| |
13 | 13 |
| |
14 |
| - | |
| 14 | + | |
15 | 15 |
| |
16 | 16 |
| |
17 | 17 |
| |
| |||
594 | 594 |
| |
595 | 595 |
| |
596 | 596 |
| |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
597 | 608 |
| |
598 | 609 |
| |
599 | 610 |
| |
600 | 611 |
| |
601 | 612 |
| |
602 | 613 |
| |
| 614 | + | |
603 | 615 |
| |
604 |
| - | |
| 616 | + | |
605 | 617 |
| |
606 | 618 |
| |
607 | 619 |
| |
| |||
615 | 627 |
| |
616 | 628 |
| |
617 | 629 |
| |
618 |
| - | |
| 630 | + | |
619 | 631 |
| |
620 | 632 |
| |
621 | 633 |
| |
622 | 634 |
| |
623 | 635 |
| |
624 |
| - | |
| 636 | + | |
625 | 637 |
| |
626 | 638 |
| |
627 | 639 |
| |
| |||
697 | 709 |
| |
698 | 710 |
| |
699 | 711 |
| |
700 |
| - | |
| 712 | + | |
701 | 713 |
| |
702 | 714 |
| |
703 | 715 |
| |
|
Lines changed: 15 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
20 | 20 |
| |
21 | 21 |
| |
22 | 22 |
| |
23 |
| - | |
| 23 | + | |
24 | 24 |
| |
25 | 25 |
| |
26 | 26 |
| |
| |||
42 | 42 |
| |
43 | 43 |
| |
44 | 44 |
| |
45 |
| - | |
| 45 | + | |
46 | 46 |
| |
47 | 47 |
| |
48 | 48 |
| |
| |||
170 | 170 |
| |
171 | 171 |
| |
172 | 172 |
| |
173 |
| - | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
174 | 176 |
| |
175 | 177 |
| |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
176 | 188 |
| |
177 | 189 |
| |
178 | 190 |
| |
|
Lines changed: 16 additions & 18 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
12 |
| - | |
13 |
| - | |
14 |
| - | |
15 |
| - | |
16 |
| - | |
17 |
| - | |
18 |
| - | |
19 |
| - | |
20 |
| - | |
21 |
| - | |
22 |
| - | |
23 |
| - | |
24 | 11 |
| |
25 | 12 |
| |
26 | 13 |
| |
| |||
196 | 183 |
| |
197 | 184 |
| |
198 | 185 |
| |
199 |
| - | |
200 |
| - | |
201 |
| - | |
202 |
| - | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
203 | 189 |
| |
204 | 190 |
| |
205 | 191 |
| |
206 | 192 |
| |
207 | 193 |
| |
208 |
| - | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
209 | 207 |
| |
210 | 208 |
| |
211 | 209 |
| |
|
Lines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
13 | 13 |
| |
14 | 14 |
| |
15 | 15 |
| |
16 |
| - | |
| 16 | + | |
17 | 17 |
| |
18 | 18 |
| |
19 | 19 |
| |
| |||
46 | 46 |
| |
47 | 47 |
| |
48 | 48 |
| |
49 |
| - | |
| 49 | + | |
50 | 50 |
| |
51 | 51 |
| |
52 | 52 |
| |
| |||
173 | 173 |
| |
174 | 174 |
| |
175 | 175 |
| |
176 |
| - | |
| 176 | + | |
177 | 177 |
| |
178 | 178 |
| |
179 | 179 |
| |
|
Lines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
17 | 17 |
| |
18 | 18 |
| |
19 | 19 |
| |
20 |
| - | |
| 20 | + | |
21 | 21 |
| |
22 | 22 |
| |
23 | 23 |
| |
| |||
131 | 131 |
| |
132 | 132 |
| |
133 | 133 |
| |
134 |
| - | |
| 134 | + | |
135 | 135 |
| |
136 | 136 |
| |
137 | 137 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
712 | 712 |
| |
713 | 713 |
| |
714 | 714 |
| |
715 |
| - | |
| 715 | + | |
716 | 716 |
| |
717 | 717 |
| |
718 | 718 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
70 | 70 |
| |
71 | 71 |
| |
72 | 72 |
| |
73 |
| - | |
| 73 | + | |
74 | 74 |
| |
75 | 75 |
| |
76 | 76 |
| |
|
Lines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
17 | 17 |
| |
18 | 18 |
| |
19 | 19 |
| |
20 |
| - | |
| 20 | + | |
21 | 21 |
| |
22 | 22 |
| |
23 | 23 |
| |
| |||
207 | 207 |
| |
208 | 208 |
| |
209 | 209 |
| |
210 |
| - | |
| 210 | + | |
211 | 211 |
| |
212 | 212 |
| |
213 | 213 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
748 | 748 |
| |
749 | 749 |
| |
750 | 750 |
| |
751 |
| - | |
| 751 | + | |
752 | 752 |
| |
753 | 753 |
| |
754 | 754 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
74 | 74 |
| |
75 | 75 |
| |
76 | 76 |
| |
77 |
| - | |
| 77 | + | |
78 | 78 |
| |
79 | 79 |
| |
80 | 80 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
40 | 40 |
| |
41 | 41 |
| |
42 | 42 |
| |
43 |
| - | |
| 43 | + | |
44 | 44 |
| |
45 | 45 |
| |
46 | 46 |
| |
|
Lines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
4 | 4 |
| |
5 | 5 |
| |
6 | 6 |
| |
7 |
| - | |
| 7 | + | |
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
| |||
23 | 23 |
| |
24 | 24 |
| |
25 | 25 |
| |
26 |
| - | |
| 26 | + | |
27 | 27 |
| |
28 | 28 |
| |
29 | 29 |
| |
|
Lines changed: 15 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
267 | 267 |
| |
268 | 268 |
| |
269 | 269 |
| |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
270 | 281 |
| |
271 | 282 |
| |
272 | 283 |
| |
| |||
284 | 295 |
| |
285 | 296 |
| |
286 | 297 |
| |
| 298 | + | |
287 | 299 |
| |
288 |
| - | |
| 300 | + | |
289 | 301 |
| |
290 | 302 |
| |
291 | 303 |
| |
| |||
390 | 402 |
| |
391 | 403 |
| |
392 | 404 |
| |
393 |
| - | |
| 405 | + | |
394 | 406 |
| |
395 | 407 |
| |
396 | 408 |
| |
397 |
| - | |
| 409 | + | |
398 | 410 |
| |
399 | 411 |
| |
400 | 412 |
| |
|
0 commit comments
Comments
(0)