- Marcar como novo
- Marcador
- Subscrever
- Silenciar
- Subscrever fonte RSS
- Destacar
- Imprimir
- Denunciar conteúdo inapropriado
Hello,
I'd like to return exit error codes if an error occures, but I don't want to output this exit error code.
Currently I use:
But this shows not only the error message but also a "spurious" one. If I write
or simply
then the exit status code is zero.
Any ideas?
Tobias
I'd like to return exit error codes if an error occures, but I don't want to output this exit error code.
Currently I use:
if(iostat /= 0) then
write(ERROR_UNIT,*) 'Cannot open file "',trim(filename),'"'
stop 1
end if
But this shows not only the error message but also a "spurious" one. If I write
stop "some error string"
or simply
stop
then the exit status code is zero.
Any ideas?
Tobias
- Marcas:
- Intel® Fortran Compiler
Link copiado
1 Responder
- Marcar como novo
- Marcador
- Subscrever
- Silenciar
- Subscrever fonte RSS
- Destacar
- Imprimir
- Denunciar conteúdo inapropriado
Try CALL EXIT(1) instead.

Responder
Opções do tópico
- Subscrever fonte RSS
- Marcar tópico como novo
- Marcar tópico como lido
- Flutuar este Tópico para o utilizador atual
- Marcador
- Subscrever
- Página amigável para impressora