Skip to content

Instantly share code, notes, and snippets.

Avatar

zhengfish zhengfish

  • Shanghai
View GitHub Profile
@zhengfish
zhengfish / gist:ac0507c130be811be0fa30425c63fc9a
Created Sep 27, 2019 — forked from RangelReale/gist:3e6392289d8ba1a52b6e70cdd7e10282
How to compile ffmpeg + x264 using Visual Studio 2015
View gist:ac0507c130be811be0fa30425c63fc9a
##### How to compile ffmpeg + x264 using Visual Studio 2015 #####
##### Building this way will make the DLLs compatible with SEH, so there will be no need to use /SAFESEH:NO when compiling your code #####
##### SOURCES:
### https://pracucci.com/compile-ffmpeg-on-windows-with-visual-studio-compiler.html
### https://gist.github.com/sailfish009/8d6761474f87c074703e187a2bc90bbc
### http://roxlu.com/2016/057/compiling-x264-on-windows-with-msvc
* Download "MSYS2 x86_64" from "http://msys2.github.io" and install into "C:\workspace\windows\msys64"
View libuv_tls.c
#include "stdafx.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <openssl/ssl.h>
#include <openssl/err.h>
#include <uv.h>
#define DEFAULT_PORT 7000
#define DEFAULT_BACKLOG 128
View QuickSort.cpp
#include <iostream>
void printArray(int *array, int n)
{
for (int i = 0; i < n; ++i)
std::cout << array[i] << std::endl;
}
void quickSort(int *array, int low, int high)
{
View iptables-cheatsheet.md

The netfilter hooks in the kernel and where they hook in the packet flow

The figure below calls out

  • The netfilter hooks
  • The order of table traversal
@zhengfish
zhengfish / minimal_vst2x_host.cpp
Created Sep 22, 2018 — forked from t-mat/minimal_vst2x_host.cpp
WIN32 : Minimal VST 2.x host in C++11.
View minimal_vst2x_host.cpp
// Win32 : Minimal VST 2.x Synth host in C++11.
//
// This is a simplified version of the following project by hotwatermorning :
// A sample VST Host Application for C++ Advent Calendar 2013 5th day.
// https://github.com/hotwatermorning/VstHostDemo
//
// Usage :
// 1. Compile & Run this program.
// 2. Select your VST Synth DLL.
// 3. Press QWERTY, ZXCV, etc.
@zhengfish
zhengfish / AdbCommands
Created Sep 10, 2018 — forked from Pulimet/AdbCommands
Adb useful commands list
View AdbCommands
== Adb Server
adb kill-server
adb start-server
== Adb Reboot
adb reboot
adb reboot recovery
adb reboot-bootloader
== Shell
You can’t perform that action at this time.