[MXS-3023] worker id overflow Created: 2020-06-04 Updated: 2020-06-05 Resolved: 2020-06-05 |
|
| Status: | Closed |
| Project: | MariaDB MaxScale |
| Component/s: | Core |
| Affects Version/s: | 2.3.19 |
| Fix Version/s: | 2.3.21, 2.4.10 |
| Type: | Bug | Priority: | Minor |
| Reporter: | danielforever | Assignee: | markus makela |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
In code above, id_generator is int, when it overflows, it becomes negative integer, then we will have an invalid worker_id in 2.2. in 2.3, it's different, but `get(id)` will return nullptr, this requires the calling method to check if worker is empty. Apparently, gw_process_one_new_client is not doing it:
suggested fix: change id_generator to unsigned type |
| Comments |
| Comment by danielforever [ 2020-06-04 ] |
|
Besides, some fields of statistics (server, session etc) have the same problem |