|
Home About Us A-Z Index Search * Contact Us Register Login Press ShopThe Open Brand -- Problem Reporting and Interpretations System |
Problem Report 1337 Details
Show help | Quick Search | Submit a Test Suite Support Request | Click here to view your privileges
This page provides all information on Problem Report 1337.
Report 1337 Actions
Problem Report Number 1337 Submitter's Classification Test Suite problem State Resolved Resolution Test Suite Deficiency (TSD) Problem Resolution ID TSD.X.0619 Raised 1970-01-01 08:00 Updated 2003-03-13 08:00 Published 1997-09-11 08:00 Product Standard Internationalised System Calls and Libraries Extended (UNIX 95) Certification Program The Open Brand certification program Test Suite VSU version 4.1.1 Test Identification CAPIbase/truncate 1 Problem Summary TSD4U.00198 This test may fail on implementations where the size of the size_t type differs from the off_t type. Problem Text
In the source file CAPI/tset/CAPIbase/ftruncate/dtruncate1.c
the array defined as...
static off_t size[] = {
408637, 523078, 855369, 23656, 223256, 379324, 295634, 291758,
370855, 305946, 102721, 447888, 772804, 965591, 610174, 481389,
356667, 55126, 929153, 182380, 828556, 358542, 231725, 597830,
51376, 1013655, 272352, 141191, 725490, 889089, 795243, 684552,
162692, 471233, 467545, 560235, 162942, 436950, 107003, 40844,
736616, 720584, 363167, 321228, 296696, 298759, 860807, 66002,
881526, 477264, 133160, 243851, 70814, 640019, 281602, 831119,
924278, 507734, 328760, 105659, 101784, 939059, 633956, 595080,
854026, 937278, 290602, 654082, 802493, 303165, 657613, 312759,
174255, 478045, 16688, 370292, 890152, 728490, 699802, 846900,
186974, 649176, 366417, 297509, 374323, 1015968, 39063, 52032,
516453, 652519, 576580, 548797, 857057, 799461, 737428, 994686,
113315, 312947, 257257, 782992, 0, 1024000,
};
contains 102 elements. The following line defining NUM_SIZES calculates
differently for 32 and 64 bit machines.
#define NUM_SIZES (sizeof(size)/sizeof(size_t))
On a 32 bit machine, both the sizeof(off_t) and sizeof(size_t) are the same (4)
producing a result of 102 elements.
On a 64 bit machine, the sizeof(off_t) is 8 causing the number of elements to be
204. This causes the test CAPI/tset/CAPIbase/ftruncate/ftruncate1.c to walk
of the end of the size[] array.
The #define NUM_SIZES statement should be
#define NUM_SIZES (sizeof(size)/sizeof(off_t))
to produce correct results for all machines.Test Output
TEST CASE: truncate
TEST PURPOSE #1
A successful call to int truncate(const
char *path, off_t length) shall cause the regular file
named by path to have a size of length bytes and
return 0.
PREP: Set to catch the SIGXFSZ signal
PREP: Create test file
TEST: truncate(../tmp/ftruncate1, 408637) returns 0
PREP: Stat file
TEST: File size equal to 408637
TEST: truncate(../tmp/ftruncate1, 523078) returns 0
PREP: Stat file
TEST: File size equal to 523078
TEST: truncate(../tmp/ftruncate1, 855369) returns 0
PREP: Stat file
TEST: File size equal to 855369
TEST: truncate(../tmp/ftruncate1, 23656) returns 0
PREP: Stat file
TEST: File size equal to 23656
TEST: truncate(../tmp/ftruncate1, 223256) returns 0
PREP: Stat file
TEST: File size equal to 223256
TEST: truncate(../tmp/ftruncate1, 379324) returns 0
PREP: Stat file
TEST: File size equal to 379324
TEST: truncate(../tmp/ftruncate1, 295634) returns 0
PREP: Stat file
TEST: File size equal to 295634
TEST: truncate(../tmp/ftruncate1, 291758) returns 0
PREP: Stat file
TEST: File size equal to 291758
TEST: truncate(../tmp/ftruncate1, 370855) returns 0
PREP: Stat file
TEST: File size equal to 370855
TEST: truncate(../tmp/ftruncate1, 305946) returns 0
PREP: Stat file
TEST: File size equal to 305946
TEST: truncate(../tmp/ftruncate1, 102721) returns 0
PREP: Stat file
TEST: File size equal to 102721
TEST: truncate(../tmp/ftruncate1, 447888) returns 0
PREP: Stat file
TEST: File size equal to 447888
TEST: truncate(../tmp/ftruncate1, 772804) returns 0
PREP: Stat file
TEST: File size equal to 772804
TEST: truncate(../tmp/ftruncate1, 965591) returns 0
PREP: Stat file
TEST: File size equal to 965591
TEST: truncate(../tmp/ftruncate1, 610174) returns 0
PREP: Stat file
TEST: File size equal to 610174
TEST: truncate(../tmp/ftruncate1, 481389) returns 0
PREP: Stat file
TEST: File size equal to 481389
TEST: truncate(../tmp/ftruncate1, 356667) returns 0
PREP: Stat file
TEST: File size equal to 356667
TEST: truncate(../tmp/ftruncate1, 55126) returns 0
PREP: Stat file
TEST: File size equal to 55126
TEST: truncate(../tmp/ftruncate1, 929153) returns 0
PREP: Stat file
TEST: File size equal to 929153
TEST: truncate(../tmp/ftruncate1, 182380) returns 0
PREP: Stat file
TEST: File size equal to 182380
TEST: truncate(../tmp/ftruncate1, 828556) returns 0
PREP: Stat file
TEST: File size equal to 828556
TEST: truncate(../tmp/ftruncate1, 358542) returns 0
PREP: Stat file
TEST: File size equal to 358542
TEST: truncate(../tmp/ftruncate1, 231725) returns 0
PREP: Stat file
TEST: File size equal to 231725
TEST: truncate(../tmp/ftruncate1, 597830) returns 0
PREP: Stat file
TEST: File size equal to 597830
TEST: truncate(../tmp/ftruncate1, 51376) returns 0
PREP: Stat file
TEST: File size equal to 51376
TEST: truncate(../tmp/ftruncate1, 1013655) returns 0
PREP: Stat file
TEST: File size equal to 1013655
TEST: truncate(../tmp/ftruncate1, 272352) returns 0
PREP: Stat file
TEST: File size equal to 272352
TEST: truncate(../tmp/ftruncate1, 141191) returns 0
PREP: Stat file
TEST: File size equal to 141191
TEST: truncate(../tmp/ftruncate1, 725490) returns 0
PREP: Stat file
TEST: File size equal to 725490
TEST: truncate(../tmp/ftruncate1, 889089) returns 0
PREP: Stat file
TEST: File size equal to 889089
TEST: truncate(../tmp/ftruncate1, 795243) returns 0
PREP: Stat file
TEST: File size equal to 795243
TEST: truncate(../tmp/ftruncate1, 684552) returns 0
PREP: Stat file
TEST: File size equal to 684552
TEST: truncate(../tmp/ftruncate1, 162692) returns 0
PREP: Stat file
TEST: File size equal to 162692
TEST: truncate(../tmp/ftruncate1, 471233) returns 0
PREP: Stat file
TEST: File size equal to 471233
TEST: truncate(../tmp/ftruncate1, 467545) returns 0
PREP: Stat file
TEST: File size equal to 467545
TEST: truncate(../tmp/ftruncate1, 560235) returns 0
PREP: Stat file
TEST: File size equal to 560235
TEST: truncate(../tmp/ftruncate1, 162942) returns 0
PREP: Stat file
TEST: File size equal to 162942
TEST: truncate(../tmp/ftruncate1, 436950) returns 0
PREP: Stat file
TEST: File size equal to 436950
TEST: truncate(../tmp/ftruncate1, 107003) returns 0
PREP: Stat file
TEST: File size equal to 107003
TEST: truncate(../tmp/ftruncate1, 40844) returns 0
PREP: Stat file
TEST: File size equal to 40844
TEST: truncate(../tmp/ftruncate1, 736616) returns 0
PREP: Stat file
TEST: File size equal to 736616
TEST: truncate(../tmp/ftruncate1, 720584) returns 0
PREP: Stat file
TEST: File size equal to 720584
TEST: truncate(../tmp/ftruncate1, 363167) returns 0
PREP: Stat file
TEST: File size equal to 363167
TEST: truncate(../tmp/ftruncate1, 321228) returns 0
PREP: Stat file
TEST: File size equal to 321228
TEST: truncate(../tmp/ftruncate1, 296696) returns 0
PREP: Stat file
TEST: File size equal to 296696
TEST: truncate(../tmp/ftruncate1, 298759) returns 0
PREP: Stat file
TEST: File size equal to 298759
TEST: truncate(../tmp/ftruncate1, 860807) returns 0
PREP: Stat file
TEST: File size equal to 860807
TEST: truncate(../tmp/ftruncate1, 66002) returns 0
PREP: Stat file
TEST: File size equal to 66002
TEST: truncate(../tmp/ftruncate1, 881526) returns 0
PREP: Stat file
TEST: File size equal to 881526
TEST: truncate(../tmp/ftruncate1, 477264) returns 0
PREP: Stat file
TEST: File size equal to 477264
TEST: truncate(../tmp/ftruncate1, 133160) returns 0
PREP: Stat file
TEST: File size equal to 133160
TEST: truncate(../tmp/ftruncate1, 243851) returns 0
PREP: Stat file
TEST: File size equal to 243851
TEST: truncate(../tmp/ftruncate1, 70814) returns 0
PREP: Stat file
TEST: File size equal to 70814
TEST: truncate(../tmp/ftruncate1, 640019) returns 0
PREP: Stat file
TEST: File size equal to 640019
TEST: truncate(../tmp/ftruncate1, 281602) returns 0
PREP: Stat file
TEST: File size equal to 281602
TEST: truncate(../tmp/ftruncate1, 831119) returns 0
PREP: Stat file
TEST: File size equal to 831119
TEST: truncate(../tmp/ftruncate1, 924278) returns 0
PREP: Stat file
TEST: File size equal to 924278
TEST: truncate(../tmp/ftruncate1, 507734) returns 0
PREP: Stat file
TEST: File size equal to 507734
TEST: truncate(../tmp/ftruncate1, 328760) returns 0
PREP: Stat file
TEST: File size equal to 328760
TEST: truncate(../tmp/ftruncate1, 105659) returns 0
PREP: Stat file
TEST: File size equal to 105659
TEST: truncate(../tmp/ftruncate1, 101784) returns 0
PREP: Stat file
TEST: File size equal to 101784
TEST: truncate(../tmp/ftruncate1, 939059) returns 0
PREP: Stat file
TEST: File size equal to 939059
TEST: truncate(../tmp/ftruncate1, 633956) returns 0
PREP: Stat file
TEST: File size equal to 633956
TEST: truncate(../tmp/ftruncate1, 595080) returns 0
PREP: Stat file
TEST: File size equal to 595080
TEST: truncate(../tmp/ftruncate1, 854026) returns 0
PREP: Stat file
TEST: File size equal to 854026
TEST: truncate(../tmp/ftruncate1, 937278) returns 0
PREP: Stat file
TEST: File size equal to 937278
TEST: truncate(../tmp/ftruncate1, 290602) returns 0
PREP: Stat file
TEST: File size equal to 290602
TEST: truncate(../tmp/ftruncate1, 654082) returns 0
PREP: Stat file
TEST: File size equal to 654082
TEST: truncate(../tmp/ftruncate1, 802493) returns 0
PREP: Stat file
TEST: File size equal to 802493
TEST: truncate(../tmp/ftruncate1, 303165) returns 0
PREP: Stat file
TEST: File size equal to 303165
TEST: truncate(../tmp/ftruncate1, 657613) returns 0
PREP: Stat file
TEST: File size equal to 657613
TEST: truncate(../tmp/ftruncate1, 312759) returns 0
PREP: Stat file
TEST: File size equal to 312759
TEST: truncate(../tmp/ftruncate1, 174255) returns 0
PREP: Stat file
TEST: File size equal to 174255
TEST: truncate(../tmp/ftruncate1, 478045) returns 0
PREP: Stat file
TEST: File size equal to 478045
TEST: truncate(../tmp/ftruncate1, 16688) returns 0
PREP: Stat file
TEST: File size equal to 16688
TEST: truncate(../tmp/ftruncate1, 370292) returns 0
PREP: Stat file
TEST: File size equal to 370292
TEST: truncate(../tmp/ftruncate1, 890152) returns 0
PREP: Stat file
TEST: File size equal to 890152
TEST: truncate(../tmp/ftruncate1, 728490) returns 0
PREP: Stat file
TEST: File size equal to 728490
TEST: truncate(../tmp/ftruncate1, 699802) returns 0
PREP: Stat file
TEST: File size equal to 699802
TEST: truncate(../tmp/ftruncate1, 846900) returns 0
PREP: Stat file
TEST: File size equal to 846900
TEST: truncate(../tmp/ftruncate1, 186974) returns 0
PREP: Stat file
TEST: File size equal to 186974
TEST: truncate(../tmp/ftruncate1, 649176) returns 0
PREP: Stat file
TEST: File size equal to 649176
TEST: truncate(../tmp/ftruncate1, 366417) returns 0
PREP: Stat file
TEST: File size equal to 366417
TEST: truncate(../tmp/ftruncate1, 297509) returns 0
PREP: Stat file
TEST: File size equal to 297509
TEST: truncate(../tmp/ftruncate1, 374323) returns 0
PREP: Stat file
TEST: File size equal to 374323
TEST: truncate(../tmp/ftruncate1, 1015968) returns 0
PREP: Stat file
TEST: File size equal to 1015968
TEST: truncate(../tmp/ftruncate1, 39063) returns 0
PREP: Stat file
TEST: File size equal to 39063
TEST: truncate(../tmp/ftruncate1, 52032) returns 0
PREP: Stat file
TEST: File size equal to 52032
TEST: truncate(../tmp/ftruncate1, 516453) returns 0
PREP: Stat file
TEST: File size equal to 516453
TEST: truncate(../tmp/ftruncate1, 652519) returns 0
PREP: Stat file
TEST: File size equal to 652519
TEST: truncate(../tmp/ftruncate1, 576580) returns 0
PREP: Stat file
TEST: File size equal to 576580
TEST: truncate(../tmp/ftruncate1, 548797) returns 0
PREP: Stat file
TEST: File size equal to 548797
TEST: truncate(../tmp/ftruncate1, 857057) returns 0
PREP: Stat file
TEST: File size equal to 857057
TEST: truncate(../tmp/ftruncate1, 799461) returns 0
PREP: Stat file
TEST: File size equal to 799461
TEST: truncate(../tmp/ftruncate1, 737428) returns 0
PREP: Stat file
TEST: File size equal to 737428
TEST: truncate(../tmp/ftruncate1, 994686) returns 0
PREP: Stat file
TEST: File size equal to 994686
TEST: truncate(../tmp/ftruncate1, 113315) returns 0
PREP: Stat file
TEST: File size equal to 113315
TEST: truncate(../tmp/ftruncate1, 312947) returns 0
PREP: Stat file
TEST: File size equal to 312947
TEST: truncate(../tmp/ftruncate1, 257257) returns 0
PREP: Stat file
TEST: File size equal to 257257
TEST: truncate(../tmp/ftruncate1, 782992) returns 0
PREP: Stat file
TEST: File size equal to 782992
TEST: truncate(../tmp/ftruncate1, 0) returns 0
PREP: Stat file
TEST: File size equal to 0
TEST: truncate(../tmp/ftruncate1, 1024000) returns 0
PREP: Stat file
TEST: File size equal to 1024000
TEST: truncate(../tmp/ftruncate1, 0) returns 0
ERROR: truncate failed, errno = 27(EFBIG - File too large)
1 FAILReview Information
Review Type TSMA Review Start Date null Completed null Status Complete Review Recommendation No Resolution Given Review Response
We agree this is a test suite deficiency in the test
suite version(s) listed.
Review Type SA Review Start Date null Completed null Status Complete Review Resolution Test Suite Deficiency (TSD) Review Conclusion
This is an agreed Test Suite Deficiency.
Problem Reporting System Options:
- View Report 1337
- List All PRs
- Search Reports
- Email the System Administrator
- View the The Open Brand Interpretations Database User Manual
Contact the Certification Authority