-
-
Notifications
You must be signed in to change notification settings - Fork 544
Throw invalid argument exception in camera plugin #2496
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
Comments
Ah, sounds like you're right. Do you mind making a pull request? |
👌, Done in PR 2498 |
I see now that the PR can't be cherry picked in v2 branch. |
Sure, you can make a backport PR as well. |
I assume we can close this, otherwise let me know. |
I'm sorry for the delay I had some busy days at work, but give me some more days to analyze this issue, because the problem is still present and my xml parameter file still crash the library in the same point. As far as i understood until now there is the function CameraDefinition::get_option_str that take the string representation of a camera parameter value and return the correct parameter object. The problem is that the string representation of the CAM_ZOOM parameter (for instance) is "ParamValue{uint32_t:1}" but this string is converted to an integer by the ParamValue class using a std::stoul function and this throw the exception. I'm trying to understand why the string "ParamValue{uint32_t:1}" is passed as argument to CameraDefinition::get_option_str instead of a simple string containing "1" that will be correctly handled by the ParamValue conversion function.. |
This piece of code in camera_definition.cpp at row 745 (in main)
Is throwing an invalid argument exception because option_name can't be converted to an unsigned integer.
Maybe is a typo?
I changed
with
and now the library i working normally.
The following is the xml file that is throwing the exception when is parsed.
The text was updated successfully, but these errors were encountered: