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 <stdio.h> | |
#include <unistd.h> | |
#include <signal.h> | |
#include <errno.h> | |
#include <stdbool.h> | |
#include <stdlib.h> | |
#include <err.h> | |
#include <sys/types.h> | |
#include <sys/wait.h> |
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
! XTerm resources | |
! | |
! Remember to run `xrdb < .Xresources` after changing anything. | |
! | |
! Tavis Ormandy <[email protected]> | |
! Set the default UI font (menus, toolbar, etc) | |
XTerm*XftFont: Segoe UI:size=10:antialias=true:style=Regular | |
! Color of UI Components |
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
! Set the default XTerm UI font (menus, toolbar, etc) | |
XTerm*XftFont: Courier:size=10:antialias=true:style=Regular | |
! All my resources are available here (I disable the Xaw3D effect, I think it looks a bit dated!) | |
! https://gist.github.com/taviso/a4543b1752fba55017e8fcc2fe052c0a | |
! It looks like this: https://imgur.com/a/m2PGuuz | |
! |
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 <stdio.h> | |
#include <windows.h> | |
#include <fwpmu.h> | |
#include <sddl.h> | |
#include <malloc.h> | |
// | |
// Attempt to reset a FWP Engine Security Descriptor. | |
// For https://github.com/henrypp/simplewall/issues/680 |
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 | |
# | |
# $ bash test.sh --my_opt=foo --my_opt bar | |
# option_index was int:0 | |
# foo | |
# option_index was int:0 | |
# bar | |
if ! source ctypes.sh; then | |
echo please install ctypes.sh |
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
declare -ar _status=( | |
[ 0]=😀 # Success | |
[ 1]=🤨 # Error | |
[129]=📞 # SIGHUP | |
[130]=🛑 # SIGINT | |
[131]="(╯°□°)╯︵ ┻━┻" # SIGQUIT | |
[132]=👮 # SIGILL | |
[133]=🐍 # SIGTRAP | |
[134]=💥 # SIGABRT |
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 <stdio.h> | |
#include <stdint.h> | |
#include <string.h> | |
/* | |
$ gcc fbmon.c | |
$ ./a.out | |
*** stack smashing detected ***: <unknown> terminated | |
Aborted (core dumped) |
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
# man equivalent for msdn pages so I can look them up in the console. | |
function msdn() | |
{ | |
local lucky="https://www.google.com/search?btnI" | |
local query="q=site:docs.microsoft.com+inurl:/en-us/windows/desktop/" | |
local title="Microsoft Developer Network" | |
local cache="${HOME}/.msdn/" | |
if ! type lynx > /dev/null; then | |
echo "error: lynx is not installed, please install it." 1>&2 |
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
%!PS | |
% This is ghostscript bug #699687 (split out from bug #699654) | |
% ImageMagick define setpagedevice, just remove their definition. This doesn't | |
% do anything if not using ImageMagick. | |
userdict /setpagedevice undef | |
% function to check if we're on Linux or Windows | |
/iswindows { | |
% Just checking if paths contain drive |
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 <windows.h> | |
#include <winternl.h> | |
#include <stdio.h> | |
#pragma comment(lib, "user32") | |
#pragma comment(lib, "gdi32") | |
typedef struct _LARGE_STRING { | |
ULONG Length; | |
ULONG MaximumLength:31; |
NewerOlder