Incidencia #47731

Path finding: Make MC and EC unsigned everywhere

Abrir Fecha: 2023-04-01 15:46 Última actualización: 2023-04-07 23:44

Informador:
Propietario:
Tipo:
Estado:
Cerrado
Componente:
Prioridad:
5 - Medium
Gravedad:
5 - Medium
Resolución:
Fixed
Fichero:
2

Details

While I don't expect this to fix path finding overflow alain_bkr saw on https://osdn.net/projects/freeciv/ticket/46286#comment:12505:46286:1679918727 , this should be a step to the right direction, and potentially already fix some other cases.

As path_finding.h comments say, MC and EC should always be positive. However, current code treats them as signed ints almost everywhere. Turn them to unsigned instead.

Ticket History (3/5 Histories)

2023-04-01 15:46 Updated by: cazfi
  • New Ticket "Path finding: Make MC and EC unsigned everywhere" created
2023-04-01 15:59 Updated by: cazfi
  • Propietario Update from (Ninguno) to cazfi
  • Resolución Update from Ninguno to Accepted
Comentario

Mostly untested patch, but still a commit candidate (I'll test while it's in review).

2023-04-07 23:44 Updated by: cazfi
  • Estado Update from Open to Cerrado
  • Resolución Update from Accepted to Fixed

Editar

Please login to add comment to this ticket » Entrar