Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Jun 25th, 2011  |  syntax: C  |  size: 2.86 KB  |  views: 58  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. /*******************************************************************************
  2.  
  3. License:
  4. This software was developed at the National Institute of Standards and
  5. Technology (NIST) by employees of the Federal Government in the course
  6. of their official duties. Pursuant to title 17 Section 105 of the
  7. United States Code, this software is not subject to copyright protection
  8. and is in the public domain. NIST assumes no responsibility  whatsoever for
  9. its use by other parties, and makes no guarantees, expressed or implied,
  10. about its quality, reliability, or any other characteristic.
  11.  
  12. This software has been determined to be outside the scope of the EAR
  13. (see Part 734.3 of the EAR for exact details) as it has been created solely
  14. by employees of the U.S. Government; it is freely distributed with no
  15. licensing requirements; and it is considered public domain.  Therefore,
  16. it is permissible to distribute this software as a free download from the
  17. internet.
  18.  
  19. Disclaimer:
  20. This software was developed to promote biometric standards and biometric
  21. technology testing for the Federal Government in accordance with the USA
  22. PATRIOT Act and the Enhanced Border Security and Visa Entry Reform Act.
  23. Specific hardware and software products identified in this software were used
  24. in order to perform the software development.  In no case does such
  25. identification imply recommendation or endorsement by the National Institute
  26. of Standards and Technology, nor does it imply that the products and equipment
  27. identified are necessarily the best available for the purpose.
  28.  
  29. *******************************************************************************/
  30.  
  31. /******************************************************************************
  32.       PACKAGE: ANSI/NIST 2007 Standard Reference Implementation
  33.  
  34.       FILE:    HISTOGEN.H
  35.  
  36.       AUTHORS: Bruce Bandini
  37.       DATE:    05/18/2010
  38.  
  39. *******************************************************************************/
  40. #ifndef _HISTOGEN_H
  41. #define _HISTOGEN_H
  42.  
  43. #define str_eq(s1,s2)  (!strcmp ((s1),(s2)))
  44.  
  45. /* If filemask = *, then getopt adds files in current dir to non-options list.
  46.    For a correctly formed command line, argc is always <= 4. */
  47. #define MAX_ARGC    4
  48. #define NUM_OPTIONS 4
  49.  
  50. #define CMD_LEN 512
  51. #define FILESYS_PATH_LEN 256
  52. #define READ_LINE_BUFFER 256
  53. #define MAX_FIELD_NUM_CHARS 12
  54. #define MAX_FIELD_NUMS 30
  55. #define ALLOC_BLOCK_SIZE 10
  56. #define HISTOGEN_LOG_FNAME "histogen.log"
  57.  
  58. typedef struct histo HISTO;
  59. struct histo {
  60.   char  field_num[12];
  61.   int   count;
  62.   HISTO *next;
  63. };
  64.  
  65. HISTO *histo_head;
  66.  
  67. enum {
  68.   INCLUDE_INVALID_FILES=5,
  69.   INCLUDE_FIELD_SEPARATORS,
  70.   INCLUDE_NEWLINE_CHARS,
  71.   INCLUDE_SPACE_CHARS
  72. };
  73.  
  74. enum {
  75.   FALSE=0,
  76.   TRUE=1
  77. };
  78.  
  79. /******************************************************************************/
  80. /* histogen.c */
  81. extern int process_file(const char *);
  82. extern int initialize_linked_list();
  83. extern int output_linked_list(FILE *);
  84.  
  85. #endif /* !_HISTOGEN_H */
clone this paste RAW Paste Data