~ubuntu-branches/ubuntu/vivid/emscripten/vivid

« back to all changes in this revision

Viewing changes to tests/hello_world_file.cpp

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2013-05-02 13:11:51 UTC
  • Revision ID: package-import@ubuntu.com-20130502131151-q8dvteqr1ef2x7xz
Tags: upstream-1.4.1~20130504~adb56cb
ImportĀ upstreamĀ versionĀ 1.4.1~20130504~adb56cb

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#include <stdio.h>
 
2
int main() {
 
3
  FILE *file = fopen("tests/hello_world_file.txt", "rb");
 
4
  while (!feof(file)) {
 
5
    char c = fgetc(file);
 
6
    if (c != EOF) {
 
7
      putchar(c);
 
8
    }
 
9
  }
 
10
  fclose (file);
 
11
  return 0;
 
12
}
 
13