File: finitest.c

package info (click to toggle)
biew 5.6.2-2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 4,000 kB
  • ctags: 7,157
  • sloc: ansic: 50,860; asm: 809; makefile: 396; pascal: 371
file content (39 lines) | stat: -rw-r--r-- 713 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/**
   Test of .ini file library.
   Written by Nick Kurshev 2000
   Use, distribute, and modify this program freely.
   This subset version is hereby donated to the public domain
*/

#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>

#include "biewlib/file_ini.h"

char **ArgVector;
unsigned ArgCount;

static tBool __FASTCALL__ MyProc(IniInfo * info)
{
  printf("[ %s ] < %s > %s = %s\n"
         ,info->section
         ,info->subsection
         ,info->item
         ,info->value);
  return 0;
}

int main( int argc, char * argv[] )
{
  if(argc < 2)
  {
     printf("Too few\n\r");
     return EXIT_FAILURE;
  }
  __init_sys();
  FiProgress(argv[1],MyProc);
  __term_sys();
  return EXIT_SUCCESS;
}