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

Revise NULL pointers that are returned intentionally? #84

Open
datbth opened this issue Mar 23, 2022 · 0 comments
Open

Revise NULL pointers that are returned intentionally? #84

datbth opened this issue Mar 23, 2022 · 0 comments

Comments

@datbth
Copy link
Contributor

datbth commented Mar 23, 2022

See Note number 1 of #83.

There are cases where Libxlsxwriter returns a NULL pointer intentionally (rather than because of a memory error).
In those cases, I think FastExcel should return nil instead of a Struct of null pointer, especially because further usage on the Struct is likely to yield segmentation fault error and crashes the whole process (rather than just a Ruby RuntimeError when using nil values improperly).

For example:

  • WorkbookWrappers#get_worksheet_by_name when worksheet is not found
  • WorkbookWrappers#default_format when there are no formats?
  • WorksheetWrappers#find_row when row is not found?
@datbth datbth changed the title Revise NULL pointers that are returned intentionally Revise NULL pointers that are returned intentionally? Mar 23, 2022
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