00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #include "kerngen/pilot.h"
00015
00016
00017
00018
00019
00020
00021
00022
00023 #include <stdio.h>
00024 #include "kerngen/fortchar.h"
00025 int fchput(pttext,ftext,lgtext)
00026 char *pttext;
00027 #if defined(CERNLIB_QMCRY)
00028 _fcd ftext;
00029 #endif
00030 #if !defined(CERNLIB_QMCRY)
00031 char *ftext;
00032 #endif
00033 int lgtext;
00034 {
00035 char *utext;
00036 int limit, jcol;
00037 int nhave;
00038
00039 limit = lgtext;
00040 jcol = 0;
00041 #if defined(CERNLIB_QMCRY)
00042 utext = _fcdtocp(ftext);
00043 #endif
00044 #if !defined(CERNLIB_QMCRY)
00045 utext = ftext;
00046 #endif
00047 if (pttext == NULL) goto out;
00048
00049
00050 for (jcol = 0; jcol < limit; jcol++)
00051 { if (*pttext == '\0') break;
00052 *utext++ = *pttext++;
00053 }
00054
00055 out: nhave = jcol;
00056 for (; jcol < limit; jcol++) *utext++ = ' ';
00057 return nhave;
00058 }
00059