1
0
mirror of https://github.com/kalmarek/PropertyT.jl.git synced 2024-11-14 14:15:28 +01:00

call flush_cstdio() AFTER redirect_stdout

to fix SCS log buffering issue
This commit is contained in:
kalmarek 2017-09-19 17:37:35 +02:00
parent 0693455656
commit dbca3945a8

View File

@ -58,11 +58,8 @@ end
function solve_SDP(SDP_problem)
info(logger, Base.repr(SDP_problem))
# to change buffering mode of stdout to _IOLBF (line bufferin)
# see https://github.com/JuliaLang/julia/issues/8765
ccall((:printf, "libc"), Int, (Ptr{UInt8},), "\n");
o = redirect_stdout(solver_logger.handlers["solver_log"].io)
Base.Libc.flush_cstdio()
t = @timed solution_status = JuMP.solve(SDP_problem)
info(logger, timed_msg(t))