Skip to content

Instantly share code, notes, and snippets.

@lhuard1A
Created September 2, 2015 16:30
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save lhuard1A/f88cce7487e84ff7a9e8 to your computer and use it in GitHub Desktop.
Save lhuard1A/f88cce7487e84ff7a9e8 to your computer and use it in GitHub Desktop.
How to create a GO program that cores…
package main
import (
"fmt"
)
// #include <stdlib.h>
// #include "signal.h"
import "C"
func main() {
fmt.Println("Good bye!")
C.signal(C.SIGABRT, 0)
C.abort()
}
#pragma once
#define _SIGNAL_H
#include <bits/signum.h>
void (*signal(int sig, int func))(int);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment