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

Cleanup capturing signals #1

Open
GoogleCodeExporter opened this issue Jul 15, 2015 · 0 comments
Open

Cleanup capturing signals #1

GoogleCodeExporter opened this issue Jul 15, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

1. Execute the following program:

package main

import (
    "code.google.com/p/gopass"
    "time"
)

func main() {
    _, err := gopass.GetPass("password:")
    if err != nil {
        println("error:", err)
    }
    println("Going to sleep...")
    time.Sleep(1 * time.Minute)
    println("... leaving!")
}

2. Hit CTRL+C when the program "sleeps"

We would expect the program to quit due to the receiving SIGINT. Instead the 
signal is silently captured and left unprocessed. Calling signal.Stop upon 
leaving GoPass passes control back to the program.

Original issue reported on code.google.com by [email protected] on 5 Jan 2014 at 11:44

Attachments:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant