about summary refs log tree commit diff homepage
path: root/runtime/klee-libc/putchar.c
blob: 4c3a57e44e4f2dd1788761aa4e353cca1651be57 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
//===-- putchar.c ---------------------------------------------------------===//
//
//                     The KLEE Symbolic Virtual Machine
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//

#include <stdio.h>
#include <unistd.h>

// Some header may #define putchar.
#undef putchar

int putchar(int c) {
  char x = c;
  write(1, &x, 1);
  return 1;
}