-
Notifications
You must be signed in to change notification settings - Fork 97
Use our own openmode_t datatype #5158
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
base: andreyk/apr_cleanup
Are you sure you want to change the base?
Conversation
# Conflicts: # indra/llcrashlogger/llcrashlock.cpp # indra/llrender/llshadermgr.cpp # indra/test/CMakeLists.txt
# Conflicts: # indra/llcrashlogger/llcrashlock.cpp # indra/llrender/llshadermgr.cpp # indra/test/CMakeLists.txt
…s_base::openmode is defined as enum in the Linux STL library which causes all kind of type problems when dealing with a collection of flags.
|
Why not overload the bitwise-or operator instead of reinventing the wheel by re-defining an enum as integers? |
A nice idea in theory. In practice the Linux STL headers already do that and it is still a mess. The whole idea of trying to force an enum into submission though static_casts all over to place to allow it to represent a flag collection is IMHO misguided but at least under Linux by now a historical fact that won't be possible to get fixed ever. |
d710b20 to
39ad777
Compare
I haven't digged in yet, but my assumption is that there is a problem with reading/writing. |
Just before this happens: WARNING #LLFile# llcommon/llfile.cpp(268) warnif : Couldn't mkdir '/tmpllcontrol-test-08dcffe6-6c1e-7f69-b039-49ff7cf255a3/' (errno 13): Permission denied So it seems that the directory can't be created and then the settings file inside neither. However not sure you can just create a directory in the root. Looks at least weird to me. I would rather guess that this path should be: '/tmp/llcontrol-test-08dcffe6-6c1e-7f69-b039-49ff7cf255a3/' instead. The slash after tmp somehow got lost. I think I know how: That got lost! The code here then causes problems. In llxml/tests/llcontrol_test.cpp (line 54) Seems that LLFile::tmpdir() is elsewhere only used with LLDir::append() to append paths when combining it with other path elements. Will need to check, but I think it would be best to use LLDir::append() in the llcontrol_test AND also add the explicit backslash to the end of LLFile::tmpdir() |
Old tmpdir explicitly adds a slash at the end, new one doesn't. |
39ad777 to
40ab3b5
Compare
Strictly speaking is LLFile::tmpdir() a bit misplaced as it is logically more an LLDir:: thing. |
|
Agree, either way trying a build with an added separator. |
|
My branch builds now on linux, but there is an odd problem with mac builds (out of disk memory?). |
I got something similar too, but it seems to have something to do with a "Secondlife Test" subproject that it tries to build even if I disable LL_TESTS in autobuild. |
That's channel, not tests. The default way to build viewer on GH out of release and project branches. |
|
Rebase it on top of current andreyk/apr_cleanup please. |
Description
Under Linux, std::ios_base::openmode is defined as an enum, which makes handling flags, which this parameter really represents, rather cumbersome. So we use our own datatype which is simply an integer.