Skip to content

Conversation

@ralphlange
Copy link
Member

Following a suggestion from @mdavidsaver, here is a better fix for #44.

Copy link
Contributor

@mdavidsaver mdavidsaver left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like progress!

- fixes epics-modules#44
- follows M. Davidsaver's suggestions for the original fix
As of caPutLog R4.1, Base 3.14 is not supported
(because caPutLog's use of epicsAtomic)
@mdavidsaver
Copy link
Contributor

I notice another bit of weirdness. The VALUE union definition is also conditional on DBR_INT64, but does not directly include any header which defines it. To make qtcreator shut up about this I tried adding #include <dbAccess.h> to caPutLogTask.h. This led me to realize that caPutJsonLogTest.cpp includes db_access.h, which does not defined DBR_INT64. So different files within caPutLog have different views of this union. Not practically a problem since the double member has the same size and (I think) the same or stricter alignment. Still, exposing this union seems a magnet for ABI problems.

@ralphlange
Copy link
Member Author

Given that this was contractor work, one would wonder how thoroughly it was reviewed...

@ralphlange
Copy link
Member Author

I opened another ticket - see above.

Hiding this union, which I support, would require review and changes in the CA Gateway interface to caPutLog. Needs coordinated PRs etc. etc.

@mdavidsaver
Copy link
Contributor

Or alternately, since this PR appears to remove base 3.14 support, adjust the yajl usage to work back to 3.15 and make JSON support unconditional. Also, I think it would be possible to restructure so that caPutJsonLogTest does not see union VALUE, which does not seem to be directly used there. This way union VALUE could be tied to dbAccess.h.

@ralphlange
Copy link
Member Author

... since this PR appears to remove base 3.14 support, ...

As far as I can see, 3.14 support has been officially removed with R4.1, by using epicsAtomic.h. This PR is just following up.

@ralphlange
Copy link
Member Author

Superseded by #50

@ralphlange ralphlange closed this Dec 11, 2025
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

Successfully merging this pull request may close these issues.

2 participants