Comments (2)
Hi @ilobilo , everything should be thread-safe except changing the path style (cwk_path_set_style/cwk_path_get_style). If you only need one path style you can set it before starting the threads and everything should be fine.
If you need to use multiple path styles in your thread you could make the following line thread local in cwalk.c (untested, requires C11):
_Thread_local static enum cwk_path_style path_style = CWK_STYLE_UNIX;
If you do that each thread should have their own path style and can act independently.
Does that help you?
from cwalk.
Yes thank you
from cwalk.
Related Issues (20)
- File path seperator unified? HOT 2
- [Bug] cwk_path_get_absolute can produce incorrect results when reusing base as buffer HOT 3
- get_absolute creates only UNIX paths if base is not absolute HOT 3
- Provide some handling examples / rethink interface HOT 3
- consider provide two set of APIs? HOT 1
- cwk_path_get_relative segfaulted HOT 7
- Dangerous fault in the behaviour of cwk_path_join HOT 9
- useless set of variable is_device_path HOT 2
- Add function that returns program location HOT 4
- Weird behavior in cwk_path_get_relative when child directory have same name as its parents HOT 4
- cwk_path_is_absolute returns an incorrect result HOT 5
- Generate pkgconfig files HOT 2
- Suggestion: functions to determine buffer size HOT 4
- Windows path root separator is normalized HOT 3
- make cwk_path_change_extension more like std::filesystem::path
- incorrect basename HOT 2
- Wide string support HOT 2
- CMake project should rely on GNUInstallDirs
- Possibility of sized variants of functions? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cwalk.