read_Daybreak2R() may not properly recognise a binary file #135
Labels
bug (potentially)
Is seems like a bug, but it's unclear what real effect it may have
Milestone
If
read_Daybreak2R()
is called on a file with no.DAT
extension, the following code is reached:However, this code is not enough to prevent an attempt to read a proper binary file (as opposed to a text file with non-ASCII characters). For example, this crashes:
A possible mitigation is to call
readLines(file, ok = FALSE)
, which raise an error directly when reading in the file if its length is not what is expected, which happens for the .binx file used above.The text was updated successfully, but these errors were encountered: