I was running into really weird problem that program SIGSEGV, after (quite a while) debug, I found the problem is, R’size attribute is in bit, instead of byte, after changing codes from R’size to R’size/8, everything works.
It … just proved I’m well trained by C/C++, mistakes I ever made include:
- Assume strings are ended with nul
- Assume backslash needs to be escaped
- Assume “or” is bit-wise operation
- Assume R’Size returns value in byte
Could be more, but these are what I can recall.
Now I can move on with PPCam again, let’s see when will be the next blocker.