-
Notifications
You must be signed in to change notification settings - Fork 21
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
C++ library and PHP PECL #1
Comments
Thanks for the interest in femtozip. You are correct there is no publicly available php module for femtozip. Thanks for reporting these issues. In response to the specific issues:
Can you provide some color on scenarios where you expect (3) above to occur? Thanks! |
gtoubassi
added a commit
that referenced
this issue
Dec 28, 2011
1. Throw runtime_errors consistently rather than bare char *. 2. At the C api level, fz_load_model swallows runtime_error and returns null. Is this the right thing? 3. Attempt to handle bad streams when reading a model.
Is there a fork containing the pecl changes? I don't want to reinvent the wheel. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Could not find an email address to contact "gtoubassi" so leaving a note here.
The wiki mentions its in use in production at a PHP site but there is no PHP module. Is this built but not released?
I'm not a C/C++ programmer and tried to tackle creating a PHP PECL extension but ran into the following problems:
A) The C++ library has no error checking or exception handling for all error cases.
B) Throws error on invalid model file (passing a non-existing file). This was fixed by checking file.good().
C) Throws error on broken model file (passing a file but not a valid model). I could not catch the error in C++ using try/catch so not sure what's going on. Again, I have little experience in C++.
D) Throws error on decompression of a string that is not a valid femtozip compressed string.
My half-baked PHP PECL module works only in a perfect environment where everything passed to it is perfect but would like the ability to handle real-world usage where bad data is throw at it and be able to recover and not crash due to errors.
Would love to have femtozip working in production and need some assistance.
The text was updated successfully, but these errors were encountered: