HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- termcap, terminfo
Operating System - HP-UX
1833609
Members
3417
Online
110062
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
06-29-2001 07:44 AM
06-29-2001 07:44 AM
termcap, terminfo
I am using tgetent in a program to get termcap terminfo for vt220. The function is passing a error and not finding the terminfo. Any suggestions.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-29-2001 08:27 AM
06-29-2001 08:27 AM
Re: termcap, terminfo
Hi,
I just created a short program to do a tgetent(dummy,(char *) NULL) to get the terminal specified by TERM and also tgetent(dummy,"vt220") to get a hardset value and both returned 0 as expected. I then followed with a call to tgetstr("cl",&area) and the returned value was as expected.
Have you tried an untic vt220 to see if you have a corrupt terminfo entry? I haven't used the termcap style calls in many moons (> 10 years) and always use the terminfo commands instead.
Regards, Clay
I just created a short program to do a tgetent(dummy,(char *) NULL) to get the terminal specified by TERM and also tgetent(dummy,"vt220") to get a hardset value and both returned 0 as expected. I then followed with a call to tgetstr("cl",&area) and the returned value was as expected.
Have you tried an untic vt220 to see if you have a corrupt terminfo entry? I haven't used the termcap style calls in many moons (> 10 years) and always use the terminfo commands instead.
Regards, Clay
If it ain't broke, I can fix that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-29-2001 08:47 AM
06-29-2001 08:47 AM
Re: termcap, terminfo
What version of hpux are you on I am on 11. Could you shoot me the code you used. My code might be wrong. Is a error return 0 good or bad.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-29-2001 09:05 AM
06-29-2001 09:05 AM
Re: termcap, terminfo
Hi,
Zero is the normal exit code and indicates that all is well. -1 is returned on error for integer functions and a NULL pointer for *char functions in curses.
Here's is my sample code and it runs under the Ansi C compiler on both 11.0 and 11i. It will not compile (or at least I didn't try very hard) under aCC becuase tgetent is no defined. You really should be using this function because the documentation for many years has stated that the termcap emulation functions are going away. It appears to have done so under aCC. I think if you switch to the more modern terminfo routines, you will have no problems.
Clay
Zero is the normal exit code and indicates that all is well. -1 is returned on error for integer functions and a NULL pointer for *char functions in curses.
Here's is my sample code and it runs under the Ansi C compiler on both 11.0 and 11i. It will not compile (or at least I didn't try very hard) under aCC becuase tgetent is no defined. You really should be using this function because the documentation for many years has stated that the termcap emulation functions are going away. It appears to have done so under aCC. I think if you switch to the more modern terminfo routines, you will have no problems.
Clay
If it ain't broke, I can fix that.
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
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP