Open
Conversation
added 5 commits
July 19, 2017 11:46
Also update to ToolsVersion 14.0.
Also set ToolsVersion to 14.0
… ensure it works when path contains spaces. When starting Rserve from within R, always pass the port as parameter. Previously, it was not passed if port=6311. This led to use of the port 7004, the default port of Rserve.exe. (Why is the default port no longer 6311 anyway?)
…in child but must be done in parent. The child threw socket error 10038. Doc of WSADuplicateSocket states it must be called in parent process. See also (here)[https://memset.wordpress.com/2010/10/13/win32-api-passing-socket-with-ipc-method/] on how to do it correctly and (here)[https://msdn.microsoft.com/en-us/library/windows/desktop/ms682499(v=vs.85).aspx] on how to use STDIN to talk to child process.
Author
|
Hello, are you still interested in accepting my pull request? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hello again, here my 3nd pull request for the same changes. This time on the master branch as requested by @swells.
Neither the release 9.0.0 not the latest branch worked for me on Windows 10. I started investigating and finally found a fix, along with some other minor fixes (see commit messages).
The main issue I discovered was the following. When a child process is created, it fails to duplicate the socket with the incoming request.
This throws a 10038 socket error.
The reason is that the function WSADuplicateSocket is called in the child process but according to its doc
it must be called from the parent process.
This sample shows how to do it correctly. They used named pipes to transfer the socket infos to the child process. This is not very elegant as this could cause conflicts with the pipe name. So I used STDIN to communicate from parent to child, as is explained here.
It seems Windows 10 is more strict about socket duplication as it works on older Windows systems.
I tested my code on a Windows 7 PC and it worked there too.