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 <iconv.h> | |
#include <string.h> | |
#include <errno.h> | |
#include <stdint.h> | |
int conv_utf8_to_ucs2(const char* src, size_t len) | |
{ | |
iconv_t cb = iconv_open("UTF-16", "UTF-8"); | |
if (cb == (iconv_t)(-1)) |
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
/* showif.c : PUBLIC DOMAIN - Jon Mayo - August 22, 2006 | |
* - You may remove any comments you wish, modify this code any way you wish, | |
* and distribute any way you wish.*/ | |
/* finds all network interfaces and shows a little information about them. | |
* some operating systems list interfaces multiple times because of different | |
* flags, modes, etc. if you want to use this code you should be aware that | |
* duplicate interfaces is a possibility */ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.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
#!/usr/bin/env python | |
# | |
# Converts any integer into a base [BASE] number. I have chosen 62 | |
# as it is meant to represent the integers using all the alphanumeric | |
# characters, [no special characters] = {0..9}, {A..Z}, {a..z} | |
# | |
# I plan on using this to shorten the representation of possibly long ids, | |
# a la url shortenters | |
# |