[MDEV-19231] make DB_SUCCESS equals 0 Created: 2019-04-10 Updated: 2019-06-10 Resolved: 2019-04-25 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - InnoDB |
| Affects Version/s: | 10.2, 10.3, 10.4 |
| Fix Version/s: | 10.2.24, 10.3.15, 10.4.5 |
| Type: | Bug | Priority: | Major |
| Reporter: | Eugene Kosov (Inactive) | Assignee: | Eugene Kosov (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
This will make code like if ( err == DB_SUCCESS) work a bit faster because CPUs have instructions to check for zero fast. |
| Comments |
| Comment by Marko Mäkelä [ 2019-04-28 ] |
|
This cleanup revealed that a few calls to os_file_read() in MariaDB and Mariabackup 10.2 had not been adjusted to the change of the return type from Boolean to dberr_t. In 10.3, also some calls to os_file_write() were incorrect. This means that errors from these calls were being effectively ignored. That was fixed as part of applying the cleanup. |
| Comment by Marko Mäkelä [ 2019-04-29 ] |
|
In 10.4, |