Tíquete #44870

secfile_lookup_str_default() to report errors

: 2022-06-20 01:42 Última Atualização: 2023-01-07 02:53

Relator:
Dono:
(Nenhum)
Tipo:
Estado:
Aberto
Componente:
Marcos:
(Nenhum)
Prioridade:
5 - Medium
Gravidade:
5 - Medium
Resolução:
Nenhum
Arquivo:
Nenhum

Details

My comment in https://www.hostedredmine.com/issues/720559 :

--

in principle illegal (though not causing load-time error) "obsolete_by = FALSE" definition plays a role here. 'obsolete_by' is not an boolean option.

--

The reason there's no error catched, is that obsolete_by is read with secfile_lookup_str_default(), that never returns any indication of errors - it just returns the 'default' value in these cases too.

I'd like to change it to return NULL on error (and 'default' only when there's no value given in the file being read), but that might break too many places currently relying on the return value to always be an usable string.

Ticket History (2/2 Histories)

2022-06-20 01:42 Updated by: cazfi
  • New Ticket "secfile_lookup_str_default() to report errors" created
2023-01-07 02:53 Updated by: cazfi
Comentário

Interim improvement -> #46466

Attachment File List

No attachments

Editar

You are not logged in. I you are not logged in, your comment will be treated as an anonymous post. » Login