Well, that's a matter of opinion. Result of your code working on requestor's files:
You are right when you say line 5 etc. is different, but old line 6 equals new line 5, so a resync should take place (as does diff). Else long files will be entirely different should line 1 be lost... The requestor's sample output vaguely alludes he/she wants resync.
Anyhow, I regretfully apologize for the harsh wording.
Hi,
I want to write a script which will compare the 1st column of both the files and will give the difference.
e.g:-
my 1st file contains:
89 /usr
52 /usr/local
36 /tmp
92 /opt
96 /home
27 /etc/opt/EMCom
1 ... (3 Replies)
I have to compare two files for any differences, then output the lab and question number for any differences. This is what I currently have:
diff lab2.txt lab2answer.txt > lab2compare.txt
Though the output doesn't have to be sent to a .txt (or any sort of log), I found that easier, at least... (2 Replies)
Hi there,
I'm sure this question has been asked many times but I can't find any posts with information.
How can I check the differences between say lines 20 - 200 in file1 and lines 420 - 600 in file2?
Thanks in advance for any help!
js (2 Replies)
All,
PLease can you help me with a shell script which can compare two xml files and print the difference to a output file.
I have attached one such file for you reference.
<Group>
<Member ID=":Year_Quad:41501" childCount="4" fullPath="PEPSICO Year-Quad-Wk : FOLDER.52 Weeks Ending Dec... (2 Replies)
It seems like a common task, but I haven't been able to find the solution.
vitallog.txt
1310,John,Hancock
13211,Steven,Mills
122,Jane,Doe
138,Thoms,Doe
1500,Micheal,May
vitalinfo.txt
12122,Jane,Thomas
122,Janes,Does
123,Paul,Kite
**OUTPUT**
vitalfiltered.txt
12122,Jane,Thomas... (2 Replies)
Hi all,
i have 50 files .data should be same in these 50 files , so my task is to find the difference. i need a logic , which finds difference between all files and print in output file with file name where it found that difference .
i tried below logic , but its not giving me what i want.
let... (2 Replies)
Hi experts,
I am trying to compare two text files and output the difference to another file.
I'm not strictly looking for differences in text but additional text at the end of one file that isn't in another, so basically comparing the file 2 against file 1 and printing any additional text to... (9 Replies)
I am connecting to a device using telnet, I want my script to perform certain commands : ie- show device , show inventory..etc and write the output it sees from the terminal to a file.
this is what I have got :
#!/usr/bin/expect --
set running 1
spawn telnet <ip address>
expect ... (1 Reply)
Discussion started by: samantha123
1 Replies
LEARN ABOUT ULTRIX
st_writest
stio(3) Library Functions Manual stio(3)Name
st_readbinary, st_readst, st_writebinary, st_writest - routines that provide a binary read/write interface to the MIPS symbol table
Syntax
#include <syms.h>
long st_readbinary (filename, how)
char *filename;
char how;
long st_readst (fn, how, filebase, pchdr, flags)
long fn;
char how;
long filebase;
pCHDRR pchdr;
long flags;
void st_writebinary (filename, flags)
char *filename;
long flags;
void st_writest (fn, flags)
long fn;
long flags;
Description
The CHDRR structure (see cmplrs/stsupport.h and the represents a symbol table in memory. A new CHDRR can be created by reading a symbol
table in from disk. The st_readbinary and st_readst routines read a symbol table in from disk.
The routine st_readbinary takes the file name of the symbol table and assumes the symbol table header (HDRR in sym.h occurs at the begin-
ning of the file. The st_readst assumes that its file number references a file positioned at the beginning of the symbol table header and
that the filebase parameter specifies where the object or symbol table file is based (for example, non-zero for archives).
The second parameter to the read routines can be r for read only or a for appending to the symbol table. Existing local symbol, line, pro-
cedure, auxiliary, optimization, and local string tables cannot be appended. If they didn't exist on disk, they can be created. This
restriction stems from the allocation algorithm for those symbol table sections when read in from disk and follows the standard pattern for
building the symbol table.
The symbol table can be read incrementally. If pchdr is zero, st_readst assumes that a symbol table has not been read yet; therefore, it
reads in the symbol table header and file descriptors. The flags argument is a bit mask that defines what other tables should be read.
The t_p* constants for each table, defined in stsupport.h, can be ORed. If flags equals -1, all tables are read. If pchdr is set, the
tables specified by flags are added to the tables that have already been read. The pchdr's value can be taken from st_current_pchdr. See
Line number entries are encoded on disk; the read routines expand them to longs.
If the version stamp is out of date, a warning message is issued to stderr. If the magic number in the HDRR is incorrect, st_error is
called. All other errors cause the read routines to read non-zero; otherwise, a zero is returned.
The routines st_writebinary and st_writest are symmetric to the read routines, excluding the how and pchdr parameters. The flags parameter
is a bit mask that defines what table should be written. The st_p* constants for each table, defined in stsupport.h, can be ORed. If flags
equals -1, all tables are written.
The write routines write sections of the table in the approved order, as specified in the link editor specification.
Line numbers are compressed on disk.
The write routines start all sections of the symbol table on four-byte boundaries.
If the write routines encounter an error, st_error is called. After writing the symbol table, further access to the table by other routines
is undefined.
See Alsostcu(3), stfe(3), stfd(3), sym.h(5), sterror(5)stsupport.h(5)
RISC stio(3)