[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference noted::hackers_v1

Title:-={ H A C K E R S }=-
Notice:Write locked - see NOTED::HACKERS
Moderator:DIEHRD::MORRIS
Created:Thu Feb 20 1986
Last Modified:Mon Aug 03 1992
Last Successful Update:Fri Jun 06 1997
Number of topics:680
Total number of notes:5456

418.0. "Puzzle" by UTRYIT::ROBERTS (U-try-it) Tue Mar 03 1987 05:27

    
    I have a small puzzle concerning file attributes which, short of
    writing an RMS program, I have been unable to solve.

    Any hacker-type insights would be most welcome.

    If anyone's interested as to why I want to do this, I'll explain
    in a separate reply, but I think it wouldn't add anything to the
    puzzle itself.


    Problem:
	I want to create a three-line C program. Here it is.

	main()
	{
	}

    Note: This file should _not_ have a <CR> at the end.

        Additionally, the file should have the attributes

	CARRIAGE CONTROL CARRIAGE RETURN
	FORMAT STREAM_LF

    (If this seems rather weird then bear with me, there IS a reason for it.)


    What I already tried:
    	I used TECO to create the file, and then CONVERT/FDL to 
	modify its attibutes. After the CONVERT, a <CR> seems to
	have appeared at the end of the file. For the purposes of
	this puzzle, that <CR> MUST NOT BE THERE.

	Any ideas, folks? Or anyone got a program which might be able
    	to do it? (There is a program which _allegedly_ produces files
    	in this format, but we don't have it.)
    
    	Also any hacker who can make an educated guess _why_ I might 
    	want to do something like this wins a few beers at my local pub. 
    	(Transport to and from Holland is your problem.)

	Regards,

	-Nigel
T.RTitleUserPersonal
Name
DateLines
418.1EMACS?CSC32::HAGERTYDave Hagerty, TSC, Colorado SpringsFri Mar 06 1987 00:516
    Do you know that if you succeed, the program that you produce will
    log off anybody who tries to compile it under 4.4 of vms?
    
    							Dave()
    
    p.s. Use EMACS
418.2Bingo!UTRTSC::ROBERTSNigel, TSC Utrecht, DTN 838-2679Fri Mar 06 1987 04:514
    You won the beer, Dave. When are you coming to Holland?
    
    -Nigel-
    
418.3Huh?4GL::DIAMONDDave Diamond, DTN 381-2687Fri Mar 06 1987 09:596
>     Do you know that if you succeed, the program that you produce will
>     log off anybody who tries to compile it under 4.4 of vms?

How's that?

Dave
418.4QARBISTRO::HEINIf We don&#039;t Have it,You don&#039;t Need it!Fri Mar 06 1987 11:5140
    Just a minor RMS problem. It's been QARred & fixed.
    
    Hein.
    
VAX/RMS JOURNALING V1.0 QAR #00081

Corrupt stream files causes RMS to loop


PROBLEM
STATEMENT

Customer's process appears to go into an infinite loop while processing a
certain file.  The file appears to be a corrupt stream file.  The last
record of the file is missing its stream file terminator character(s) i.e.
<CR><LF>. Following the last record is simply binary zeros. 

Customer has two files, which when typed, exhibit different symptoms.

On one file, "$ TYPE" hangs the process in computable state.  The process
cannot be stopped with ^Y.  The process must be stopped with STOP/ID.

On another file, "$ TYPE" prints the contents of the file repeatedly, 
in an infinite loop.


RESPONSE

We have located the problem as RMS incorrectly processing stream files 
whose  final record does not properly terminate prior to the end of file.

There are actually two problems here: corrupt stream files are being
generated by certain programs, and RMS is incorrectly looping at end of
file when processing such corrupt stream files.

The problem with creating corrupt stream files has been forwarded to
the appropriate software engineering groups.  However, RMS should be
able to detect such corrupt files and not loop at end of file.

This problem is fixed in the special VAX/RMS Journaling 1.0 FT2 "A" kit.