Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 04-10-2012, 04:01 AM   #1
LQ Newbie
Registered: Apr 2012
Posts: 5

Rep: Reputation: Disabled
Centos 5.8 and RedHat 5.3 terminals strange behaviour


I have following problem. I have Centos 5.8 ( Final ) on Virtual Box.
I noticed very strange behavior of the terminals when resizing them.

My default shell is tcsh .

Let's assume that we have trial script try.csh with text in it:

#! /bin/tcsh -f

# Trial script

echo -n "Enter some value: "
set tmp = $<

if (${tmp} == "") then
echo "Only key [Enter] is typed"
echo "The entered value = ${tmp} "

exit 0

If I execute the command ./try.csh
First following text appears: Enter some value:

If now I resize the terminal nothing happens, which should be the case.

But if I execute the command source ./try.csh
First same text appears: Enter some value:

And now if I again change the size of the terminal the text is changed to:
Enter some value: Only key [Enter] is typed

So it seems that sourced program considers resizing of the terminal like as [ Enter ] key is typed. In the company where I work we have RedHat5.3 servers and RedHat4.7 server, on the RH5.3 this problem is also existing, which is not the case for RH4.7 ones.

Please help me to solve this issue!

Best regards,

Old 04-11-2012, 06:41 PM   #2
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911
Hi, welcome to LQ!

I don't use either of the distro's you're mentioning, and I don't use tsch (bleagh ;}).

But I note that tcsh on Slackware64 13.37 shows the exact opposite of the behaviour you
describe (works when sourced, fails when run), and debian squeeze 64 behaves as expected
in both cases (resizing doesn't "answer" the prompt).

I can only assume that the difference lies in the way the terminal emulation in used is
set-up to respond to sizing events, and that it may differ between distros and versions
of distros.

Old 04-12-2012, 03:32 AM   #3
LQ Newbie
Registered: Apr 2012
Posts: 5

Original Poster
Rep: Reputation: Disabled
Hello Tinkster,

It seems that the issue is not caused from the terminal emulator itself.
Because in Centos5.8 I have this issue using Terminal, konsole and xterm.
In RedHat5.3 I have the issue using konsole, xterm and gnome-terminal.

Best regards,



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Strange g++ behaviour? james_b Programming 8 11-17-2011 09:22 AM
Peculiar behaviour in Different terminals raghesh Linux - Server 0 03-14-2008 12:23 AM
ps -ef strange behaviour ?? lionking_x Linux - Newbie 1 11-28-2007 06:22 PM
strange behaviour marsques Slackware 11 02-15-2006 07:05 PM
Strange Behaviour! joshuarowley LQ Suggestions & Feedback 1 12-08-2005 04:36 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:44 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration