HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- LP64 migration warning
Operating System - HP-UX
1833043
Members
2852
Online
110049
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
Go to solution
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
03-09-2005 03:05 AM
03-09-2005 03:05 AM
When compiling the source-code line:
if ( strncmp( LV.zustand_dialog, "PF", 2 ) )
i get the compiler warning:
LP64 migration warning 753: Argument #3 converts 32 bit integer to long
What can i do against it ?
Many thanks in advance
if ( strncmp( LV.zustand_dialog, "PF", 2 ) )
i get the compiler warning:
LP64 migration warning 753: Argument #3 converts 32 bit integer to long
What can i do against it ?
Many thanks in advance
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-09-2005 03:09 AM
03-09-2005 03:09 AM
Re: LP64 migration warning
Cast the constant 2 to the expected type. ie 2 ==> (size_t) 2.
If it ain't broke, I can fix that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-09-2005 03:13 AM
03-09-2005 03:13 AM
Re: LP64 migration warning
Now i get:
LP64 migration warning 753: Cast converts 32 bit integer to long
..
LP64 migration warning 753: Cast converts 32 bit integer to long
..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-09-2005 03:45 AM
03-09-2005 03:45 AM
Solution
Okay, your are probably compiling with the options +DD64 and +M2. You can reduce to +M1. Under the +DD64 (or DA2.0W) models integers (and integer constants) are 32 bits while pointers, longs, and size_t's (the type of the 3rd argument in strncmp) are 64-bits.
If you want to "outbushwhack" the warning completely then
(size_t) 2L BUT you now set yourself up for the reverse potential problem if your are running +DD32. However, since +M2 requires +DD64 to be asserted, you don't get the warning for the inverse case. In any event, these are warnings only just that and the actual type conversions in either direction work and the size_t cast forces the correct behavior.
(size_t) 2L will take care of the warning.
If you want to "outbushwhack" the warning completely then
(size_t) 2L BUT you now set yourself up for the reverse potential problem if your are running +DD32. However, since +M2 requires +DD64 to be asserted, you don't get the warning for the inverse case. In any event, these are warnings only just that and the actual type conversions in either direction work and the size_t cast forces the correct behavior.
(size_t) 2L will take care of the warning.
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