Skip to content
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

Redox support #6

Merged
merged 2 commits into from
Jun 26, 2017
Merged

Redox support #6

merged 2 commits into from
Jun 26, 2017

Conversation

ids1024
Copy link
Contributor

@ids1024 ids1024 commented Jun 22, 2017

No description provided.

src/lib.rs Outdated
#[cfg(target_os = "redox")]
#[inline]
fn get_internal() -> usize {
syscall::getpid().unwrap()
Copy link
Owner

Choose a reason for hiding this comment

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

I am not familiar with Redox internals, but on Linux at least there is a distinction between the process id and the thread id. Could you please add a comment to explain why getpid is the right thing to call here? Is there even a distinction between processes and threads on Redox?

Choose a reason for hiding this comment

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

It is true that threads are simply processes on Redox, which share memory with other processes.

Copy link

@jackpot51 jackpot51 Jun 23, 2017

Choose a reason for hiding this comment

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

In other words, creating a new thread will create a new process ID

Copy link
Owner

Choose a reason for hiding this comment

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

Thanks for the clarification!

@ruuda ruuda merged commit cdff8f8 into ruuda:master Jun 26, 2017
@ruuda
Copy link
Owner

ruuda commented Jun 26, 2017

Thanks! Should I publish a new version on crates.io?

@ids1024
Copy link
Contributor Author

ids1024 commented Jun 26, 2017

Yes, that would be helpful. Thanks!

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.

3 participants