Newsgroups: fj.lang.c
Path: galaxy.trc.rwcp.or.jp!coconuts.jaist!wnoc-tyo-news!tokyonet.ad.jp!news.sainet.or.jp!news01.so-net.or.jp!nr1.scn.co.jp!news.he.net!www.nntp.primenet.com!nntp.primenet.com!howland.erols.net!worldnet.att.net!hunter.premier.net!uunet!in2.uu.net!192.244.176.52!news.iij.ad.jp!iijnet!fjyisl!news
From: simazaki@fjyisl.fujikoshi.co.jp (Yasuharu Simazaki)
Subject: =?ISO-2022-JP?B?GyRCI00jUyNDJE48QUxkIUolVSUhJSQlayVdJSQlcyU/GyhC?=
 =?ISO-2022-JP?B?GyRCITwhSyQqJDckKCRGGyhC?=
Content-Type: text/plain; charset=ISO-2022-JP
Message-ID: <1997Jan29.055747.8025@fujikoshi.co.jp>
Sender: news@fujikoshi.co.jp
Nntp-Posting-Host: vision018
Organization: fujikoshi
X-Newsreader: WinVN 0.99.3J+
Mime-Version: 1.0
Date: Wed, 29 Jan 1997 05:57:47 GMT
Lines: 108
Xref: galaxy.trc.rwcp.or.jp fj.lang.c:3554
X-originally-archived-at: http://galaxy.rwcp.or.jp/text/cgi-bin/newsarticle2?ng=fj.lang.c&nb=3554&hd=a
X-reformat-date: Mon, 18 Oct 2004 15:18:22 +0900
X-reformat-comment: Tabs were expanded into 4 column tabstops by the Galaxy's archiver. See http://katsu.watanabe.name/ancientfj/galaxy-format.html for more info.

$B#M#S#C#V#4$G!$%U%!%$%k$N%[!,%$%s%?!<$rJQ?t$G%5%U!+4X?t$KEO$9J}K!65$($F$/$@$5$$!%(B

$B%U%!%$%k(BIO $B$r(B $B%5%U!+4X?t$G9T$&(B
$B%U%!%$%k%[!,%$%s%?!<$r4X?t0z$-?t$K$9$k!!0z$-?t$OJ8;zNs$H$9$k!%%F%9%H$G$9!%(B

$B%3%s%Q%$%k$9$k$H(B

$B%3%s%O!,%$%kCf(B...
subfs.c
F:\home\shima\vc\ex1\fileio\ex5\subfs.c(13) : error C2223: '->_flag' : $B:8(B
$BB&$,9=B$BN$+6&MQBN$KBP$9$k%[!,%$%s%?$G$O$"$j$^$;$s!#(B
F:\home\shima\vc\ex1\fileio\ex5\subfs.c(14) : warning C4133: 'function' : 
'char *' $B$H(B 'struct _iobuf *' $B$N4V$G7?$K8_49@-$,$"$j$^$;$s!#(B
F:\home\shima\vc\ex1\fileio\ex5\subfs.c(15) : warning C4133: 'function' : 
'char *' $B$H(B 'struct _iobuf *' $B$N4V$G7?$K8_49@-$,$"$j$^$;$s!#(B
cl.exe $B$N<B9T%(%i!<(B
subfs.obj - $B%(%i!<(B 1$B!"7Y9p(B 2

$B$H$J$jJQ?t$K$G$-$^$;$s!%%[!,%$%s%?!<$r0z$-?t$GEO$7!$#e#o#f$J$I$r8!=P$9$kJ}K!$r65$($F(B
$B$/$@$5$$!%(B

//************************************************
//* fn f:\home\shima\vc\ex1\fileio\ex5\fpr01.c
//* $B%U%!%$%k(BIO $B$r(B $B%5%U!+4X?t$G9T$&(B
//* $B%U%!%$%k%[!,%$%s%?!<$r4X?t0z$-?t$K$9$k!!0z$-?t$OJ8;zNs$H$9$k!%(B
//*  call sub f  :subfp,subfs
//* 97.01.29 Y.Simazaki
//*************************************************
#include <stdio.h>

FILE *f4 , *f5 , *f7 , *f8;
FILE *f6 = stdout;

char f4nm[20] = { "abci.txt" };//$BF~NO%U%!%$%k(B  $BF0J*(B
char f5nm[20] = { "abci2.txt" };//$BF~NO%U%!%$%k(B2 $BD;(B sub
char f7nm[20] = { "abco.txt" };//$B=PNO%U%!%$%k(B
char f8nm[20] = { "abco2.txt" };//$B=PNO%U%!%$%k(B2    sub

char name[20]; int n;

int subfp( char fopt[] );
int subfs( char fipt[] , char fopt2[] );

void main( )
{
if(( f4 = fopen( f4nm , "r" )) == NULL ) {
fprintf( f6 , "f4 err\n" );
exit(-1);
}
if(( f5 = fopen( f5nm , "r" )) == NULL ) {
fprintf( f6 , "f5 err\n" );
exit(-1);
}
if(( f7 = fopen( f7nm , "w" )) == NULL ) exit(-1);
if(( f8 = fopen( f8nm , "w" )) == NULL ) exit(-1);

while( fscanf( f4 , "%s%d" ,name , &n ) != EOF ) {
fprintf( f6 , "%20s %3d\n" ,name , n );
fprintf( f7 , "%20s %3d\n" ,name , n );
subfp( f8 );
}
subfs( f5 , f6 );

fclose( f4 );
fclose( f5 );
fclose( f7 );
fclose( f8 );
}
//************************************************
//* fn f:\home\shima\vc\ex1\fileio\ex5\subfp.c
//*************************************************
#include <stdio.h>

char name[20]; int n;

int subfp( char fopt[] );

int subfp( char fopt[] )
{
fprintf( fopt , "%20s %3d\n" ,name , n );
return ( 0 );
}

//************************************************
//* fn f:\home\shima\vc\ex1\fileio\ex5\subfs.c
//*************************************************
#include <stdio.h>
char name[20]; int n;

int subfs( char fipt[] , char fopt2[] );

int subfs( char fipt[] , char fopt2[] )
{
while( !feof( fipt[1] )) {
fscanf( fipt , "%s%d" ,name , &n );
fprintf( fopt2 , "%s %3d\n" ,name , n );
}
return( 0 );
}

    $B!&!!!!!!!!!&!!!!!&!!!&!&!&!E!E!D!D(,(,(,(,(,(,(,(,!z(B
$BH/?.85!'(B
  $B3t<02q<R(B $BITFs1[(B   $B5;=Q3+H/It(B $BEE;R5;=QIt(B 
  $B=;=j!((B930 $BIY;3;TITFs1[K\D.(B1-1-1 TEL;0764-23-5337($BD>DL(B),FAX;0764-93-5213
  $B;aL>(B :$BEg:j!!BY<#(B Email:simazaki@fujikoshi.co.jp,$BFb@~(B2736,$BFb(Bfax4313

    $B!&!!!!!!!!!&!!!!!&!!!&!&!&!E!E!D!D(,(,(,(,(,(,(,(,!z(B

