Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

L'import paydex peut paniquer à cause d'une ligne malformée dans la source #371

Open
chrnin opened this issue Jun 25, 2021 · 0 comments
Open

Comments

@chrnin
Copy link

chrnin commented Jun 25, 2021

Dans le cas où le fichier contient une ligne de ce type:

;; jours;

On obtient cette erreur:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x90e35d]

goroutine 109 [running]:
github.com/signaux-faibles/opensignauxfaibles/lib/paydex.parsePaydexLine(0xc0210dc3c0, 0xc005108240, 0x4, 0x4, 0xc00038fe00, 0x0, 0x0)
        /home/christophe/Project/opensignauxfaibles/lib/paydex/main.go:98 +0x20d
github.com/signaux-faibles/opensignauxfaibles/lib/paydex.(*paydexParser).parseLine(0xfcd800, 0xc005108240, 0x4, 0x4, 0xc005108200)
        /home/christophe/Project/opensignauxfaibles/lib/paydex/main.go:77 +0x54
github.com/signaux-faibles/opensignauxfaibles/lib/paydex.(*paydexParser).ParseLines.func1(0xc005108240, 0x4, 0x4, 0xc005108200)
        /home/christophe/Project/opensignauxfaibles/lib/paydex/main.go:72 +0x52
github.com/signaux-faibles/opensignauxfaibles/lib/marshal.ParseLines(0xc015df0120, 0xc0259561b0, 0xc000673fb0)
        /home/christophe/Project/opensignauxfaibles/lib/marshal/parsingHelpers.go:58 +0x226
github.com/signaux-faibles/opensignauxfaibles/lib/paydex.(*paydexParser).ParseLines(0xfcd800, 0xc015df0120)
        /home/christophe/Project/opensignauxfaibles/lib/paydex/main.go:71 +0x5c
created by github.com/signaux-faibles/opensignauxfaibles/lib/marshal.runParserOnFile
        /home/christophe/Project/opensignauxfaibles/lib/marshal/parser.go:96 +0x1db
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant