1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

tools: fix vwatch.v compilation

This commit is contained in:
Delyan Angelov 2021-04-25 09:18:06 +03:00
parent aff21c976b
commit bb4f0ed4a9
No known key found for this signature in database
GPG Key ID: 66886C0F12D595ED

View File

@ -242,7 +242,7 @@ const ccontext = Context{
}
fn main() {
mut context := &ccontext
mut context := unsafe { &Context(voidptr(&ccontext)) }
context.pid = os.getpid()
context.vexe = os.getenv('VEXE')
context.is_worker = os.args.contains('-vwatchworker')
@ -282,7 +282,7 @@ fn (mut context Context) manager_main() {
fn (mut context Context) worker_main() {
context.rerun_channel = chan RerunCommand{cap: 10}
os.signal(C.SIGINT, fn () {
mut context := &ccontext
mut context := unsafe { &Context(voidptr(&ccontext)) }
context.is_exiting = true
context.kill_pgroup()
})