This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Sample implementation of a Shutdownable object. | |
*/ | |
public class SampleImpl implements Shutdownable { | |
public static void main(String[] args) { | |
SampleImpl sample = new SampleImpl(); | |
// Make the JVM call our shutdown() method upon exit. | |
ShutdownHook.registerForShutdownHook(sample); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Deletes message queue in C. | |
// For educational purposes only. | |
// Author: Vaclav Bohac | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
#include <errno.h> | |
#include <string.h> | |
#include <signal.h> |
NewerOlder