Merge pull request #780 from rxwen/master
flush the options_file before start the ycmd server
This commit is contained in:
commit
d156214f76
@ -176,7 +176,7 @@ def ForceSemanticCompletion( request_data ):
|
||||
|
||||
# A wrapper for subprocess.Popen that works around a Popen bug on Windows.
|
||||
def SafePopen( *args, **kwargs ):
|
||||
if kwargs.get( 'stdin', '' ) is None:
|
||||
if kwargs.get( 'stdin' ) is None:
|
||||
# We need this on Windows otherwise bad things happen. See issue #637.
|
||||
kwargs[ 'stdin' ] = subprocess.PIPE if OnWindows() else None
|
||||
|
||||
|
@ -84,6 +84,7 @@ class YouCompleteMe( object ):
|
||||
with tempfile.NamedTemporaryFile( delete = False ) as options_file:
|
||||
self._temp_options_filename = options_file.name
|
||||
json.dump( dict( self._user_options ), options_file )
|
||||
options_file.flush()
|
||||
args = [ utils.PathToPythonInterpreter(),
|
||||
_PathToServerScript(),
|
||||
'--port={0}'.format( server_port ),
|
||||
|
Loading…
Reference in New Issue
Block a user