This file contains 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
main: main.cpp | |
g++ -DFUSE_USE_VERSION=28 -D_FILE_OFFSET_BITS=64 -I/usr/local/include/osxfuse/fuse -lfuse main.cpp -o main -std=c++11 -Wall -Wextra |
This file contains 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
#!/bin/bash | |
PATH="/sbin:/bin:/usr/sbin:/usr/bin" | |
state=$(zpool status | grep state) | |
if [ "$state" != " state: ONLINE" ]; then | |
echo "Zpool status state is not ONLINE" | |
zpool status | |
exit 1 | |
fi |
This file contains 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
Homebrew build logs for qemu on macOS 10.12.5 | |
Build date: 2017-07-07 17:03:05 |
This file contains 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
cmake_minimum_required(VERSION 2.8.12) | |
project(MyKernel C CXX ASM) | |
# ... | |
add_executable(mykernel boot.s kernel_main.cpp) # + other source files | |
set_target_properties(mykernel PROPERTIES LINK_DEPENDS "${CMAKE_SOURCE_DIR}/linker.ld") | |
set_target_properties(mykernel PROPERTIES LINK_FLAGS "-T ${CMAKE_SOURCE_DIR}/linker.ld") |
This file contains 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
--- Failing tests --- | |
total number of failing tests: 68 | |
total number of succeeding tests: 890 | |
* clocks are not supported together with locks/condvars yet | |
- cnd_timedwait::success | |
- cnd_timedwait::timedout | |
- mq_timedreceive::bad | |
- mq_timedreceive::blocking | |
- mq_timedsend::bad | |
- mq_timedsend::blocking |
This file contains 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
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
my $email = 'letsencrypt@sjor.sg'; | |
my $sslroot = '/etc/ssl/private'; | |
# This script assumes every hostname under __DATA__ has its .well-known pointing to the following directory: | |
my $webroot = '/var/www/well-known'; | |
while(<DATA>) { |
This file contains 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
#include <stdint.h> | |
#include <stdio.h> | |
struct node_t { | |
node_t() : i(0), previous(0) {} | |
node_t(node_t *previous) : i(previous->i + 1), previous(previous) {} | |
uint64_t i; | |
node_t *previous; | |
}; |
This file contains 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
warnglobals.so |
This file contains 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
std::string url = "unix:///tmp/mysql.sock"; | |
std::string user = "root"; | |
std::string pass = ""; | |
std::string database = "foo"; | |
rusql::connection c; | |
try { | |
c = rusql::connection(url, user, pass, database); | |
} catch(rusql::sql_connection_error &e) { |
This file contains 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
sjors@foo:/tmp$ cat main.c | |
#include <stdio.h> | |
#include <stdlib.h> | |
int main(int argc, char *argv[]) { | |
long bar = strtol(argv[1], NULL, 10); | |
printf("bar = %ld\n", bar); | |
int foo = 5 / bar; | |
printf("I'm still here\n"); | |
return 0; |