home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 4 / DATAFILE_PDCD4.iso / utilities / utilsp / rink010 / Demo / c / segment2 < prev   
Encoding:
Text File  |  1995-06-25  |  662 b   |  42 lines

  1. // rinkdemo - second segment
  2. // (c) Ben Summers 1995
  3.  
  4. #include <stdio.h>
  5. #include <stdlib.h>
  6.  
  7. // a defintion of a number in the parent. It would be defined in a header
  8. // file. Obviously, direct access of data is not to be encouraged, but
  9. // it is possible.
  10.  
  11. extern int NumberInParent;
  12.  
  13.  
  14.  
  15. int Start(char *String, int Number)
  16. {
  17.     printf("Segment2 start, String = %s, Number = %d\n\n", String, Number);
  18.  
  19.     return Number * 2 / 3;
  20. }
  21.  
  22. void Do(void)
  23. {
  24.     printf("Segment2: NumberInParent = %d\n\n", NumberInParent);
  25. }
  26.  
  27. int Finish(int Number)
  28. {
  29.     printf("Segment2 finish called...\n\n");
  30.  
  31.     return 0;
  32. }
  33.  
  34. void NamedEntry1(void)
  35. {
  36. }
  37.  
  38. void NamedEntry2(void)
  39. {
  40. }
  41.  
  42.