Created
June 25, 2018 14:23
-
-
Save Erk-/f27763cff0f6fb6a28dbd46531c65702 to your computer and use it in GitHub Desktop.
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
#![allow ( dead_code )] | |
#![allow ( mutable_transmutes )] | |
#![allow ( non_camel_case_types )] | |
#![allow ( non_snake_case )] | |
#![allow ( non_upper_case_globals )] | |
#![allow ( unused_mut )] | |
#![feature ( extern_types )] | |
#![feature ( libc )] | |
extern crate libc; | |
extern "C" { | |
pub type _IO_FILE_plus; | |
#[no_mangle] | |
static mut _IO_2_1_stdin_: _IO_FILE_plus; | |
#[no_mangle] | |
static mut _IO_2_1_stdout_: _IO_FILE_plus; | |
#[no_mangle] | |
static mut _IO_2_1_stderr_: _IO_FILE_plus; | |
#[no_mangle] | |
static mut stdin: *mut _IO_FILE; | |
#[no_mangle] | |
static mut stdout: *mut _IO_FILE; | |
#[no_mangle] | |
static mut stderr: *mut _IO_FILE; | |
#[no_mangle] | |
fn fopen(__filename: *const libc::c_char, __modes: *const libc::c_char) | |
-> *mut FILE; | |
#[no_mangle] | |
static mut sys_nerr: libc::c_int; | |
#[no_mangle] | |
static sys_errlist: [*const libc::c_char; 0]; | |
} | |
pub type __off_t = libc::c_long; | |
#[derive ( Copy , Clone )] | |
#[repr ( C )] | |
pub struct _IO_FILE { | |
pub _flags: libc::c_int, | |
pub _IO_read_ptr: *mut libc::c_char, | |
pub _IO_read_end: *mut libc::c_char, | |
pub _IO_read_base: *mut libc::c_char, | |
pub _IO_write_base: *mut libc::c_char, | |
pub _IO_write_ptr: *mut libc::c_char, | |
pub _IO_write_end: *mut libc::c_char, | |
pub _IO_buf_base: *mut libc::c_char, | |
pub _IO_buf_end: *mut libc::c_char, | |
pub _IO_save_base: *mut libc::c_char, | |
pub _IO_backup_base: *mut libc::c_char, | |
pub _IO_save_end: *mut libc::c_char, | |
pub _markers: *mut _IO_marker, | |
pub _chain: *mut _IO_FILE, | |
pub _fileno: libc::c_int, | |
pub _flags2: libc::c_int, | |
pub _old_offset: __off_t, | |
pub _cur_column: libc::c_ushort, | |
pub _vtable_offset: libc::c_schar, | |
pub _shortbuf: [libc::c_char; 1], | |
pub _lock: *mut libc::c_void, | |
pub _offset: __off64_t, | |
pub __pad1: *mut libc::c_void, | |
pub __pad2: *mut libc::c_void, | |
pub __pad3: *mut libc::c_void, | |
pub __pad4: *mut libc::c_void, | |
pub __pad5: size_t, | |
pub _mode: libc::c_int, | |
pub _unused2: [libc::c_char; 20], | |
} | |
pub type size_t = libc::c_ulong; | |
pub type FILE = _IO_FILE; | |
pub type __off64_t = libc::c_long; | |
#[derive ( Copy , Clone )] | |
#[repr ( C )] | |
pub struct _IO_marker { | |
pub _next: *mut _IO_marker, | |
pub _sbuf: *mut _IO_FILE, | |
pub _pos: libc::c_int, | |
} | |
pub type _IO_lock_t = (); | |
unsafe fn main_0() -> libc::c_int { | |
let mut test: *mut FILE = | |
fopen(b"lol\x00" as *const u8 as *const libc::c_char, | |
b"w\x00" as *const u8 as *const libc::c_char); | |
return 0; | |
} | |
fn main() -> () { unsafe { ::std::process::exit(main_0() as i32) } } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment