HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Reding verrrrry long lines from the terminal
Operating System - HP-UX
1827414
Members
5017
Online
109965
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-23-2001 08:17 AM
05-23-2001 08:17 AM
Reding verrrrry long lines from the terminal
Hi,
I am having problems reading input from the keyboard. If the input is very long (more then 512 chars), I only get the last 512 chars from the input queue.
I looked at the termio(7) man page in the section "Input Processing an Reading Data" and it clearly states:
When the input limit is reached, all saved characters are discarded without notice.
Well, how can I get around this limitation?
For simplicity, here are simple samples of what I am trying to do. They all print only the last buffer of the input. These are all that I entered from an interactive shell:
cat
awk '{print $0}'
sed -n p # hit enter twice to see output
perl -le '$_ = <>; print'
(read line; echo $line)
For all the above, whenever there are more then 512 chars inputted, only the last set is outputted.
For the last example above I found that my problem was the EDITOR variable which was set to vi. The following works fine:
(export EDITOR=emacs; read line; echo $line)
This work perfectly, no matter how many chars are in the input.
Is it possible to have some settings (perhaps stty?), where no characters from the input will be discarded?
Thanks in advance,
--Leslie
I am having problems reading input from the keyboard. If the input is very long (more then 512 chars), I only get the last 512 chars from the input queue.
I looked at the termio(7) man page in the section "Input Processing an Reading Data" and it clearly states:
When the input limit is reached, all saved characters are discarded without notice.
Well, how can I get around this limitation?
For simplicity, here are simple samples of what I am trying to do. They all print only the last buffer of the input. These are all that I entered from an interactive shell:
cat
awk '{print $0}'
sed -n p # hit enter twice to see output
perl -le '$_ = <>; print'
(read line; echo $line)
For all the above, whenever there are more then 512 chars inputted, only the last set is outputted.
For the last example above I found that my problem was the EDITOR variable which was set to vi. The following works fine:
(export EDITOR=emacs; read line; echo $line)
This work perfectly, no matter how many chars are in the input.
Is it possible to have some settings (perhaps stty?), where no characters from the input will be discarded?
Thanks in advance,
--Leslie
If life serves you lemons, make lemonade
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Support
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP