Changeset 37924 in vbox for trunk/src/VBox/Main
- Timestamp:
- Jul 13, 2011 3:21:10 PM (14 years ago)
- svn:sync-xref-src-repo-rev:
- 72833
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-server/StorageControllerImpl.cpp
r35638 r37924 476 476 { 477 477 /* AHCI SATA supports a maximum of 30 ports. */ 478 if ( (aPortCount < 1) || (aPortCount > 30))478 if (aPortCount < 1 || aPortCount > 30) 479 479 return setError(E_INVALIDARG, 480 480 tr("Invalid port count: %lu (must be in range [%lu, %lu])"), … … 692 692 tr("Invalid controller type")); 693 693 694 if ( (aPortNumber < 0) || (aPortNumber >= 30))694 if (aPortNumber < 0 || aPortNumber >= 30) 695 695 return setError(E_INVALIDARG, 696 tr("Invalid port number: %l (must be in range [%lu, %lu])"),696 tr("Invalid port number: %ld (must be in range [%lu, %lu])"), 697 697 aPortNumber, 0, 29); 698 698 … … 764 764 if (FAILED(rc)) return rc; 765 765 766 if ( (aControllerPort < 0)767 || (aControllerPort >= (LONG)portCount)768 || (aDevice < 0)769 || (aDevice >= (LONG)devicesPerPort)766 if ( aControllerPort < 0 767 || aControllerPort >= (LONG)portCount 768 || aDevice < 0 769 || aDevice >= (LONG)devicesPerPort 770 770 ) 771 771 return setError(E_INVALIDARG, 772 tr("The port and/or count parameter are out of range [%lu:%lu]"), 773 portCount, 774 devicesPerPort); 772 tr("The port and/or device parameter are out of range: port=%d (must be in range [0, %u]), device=%u (must be in range [0, %u])"), 773 (int)aControllerPort, (int)portCount-1, (int)aDevice, (int)devicesPerPort-1); 775 774 776 775 return S_OK;
Note:
See TracChangeset
for help on using the changeset viewer.