X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs2.git;a=blobdiff_plain;f=direct%2Ftimothy_tests%2Fquick_tests%2Ftest_yaffs_open_EINVAL.c;h=35690285e2616b1f53730e7d0a7d0883583111e0;hp=17c5912ea116043063c9455a20d76ea24e2bc888;hb=24c7a59d54dbe6946be101db3c8ae38f92634129;hpb=f2c8e9cf2b72e5ac6a776a1a1b188f8595e7c35c diff --git a/direct/timothy_tests/quick_tests/test_yaffs_open_EINVAL.c b/direct/timothy_tests/quick_tests/test_yaffs_open_EINVAL.c index 17c5912..3569028 100644 --- a/direct/timothy_tests/quick_tests/test_yaffs_open_EINVAL.c +++ b/direct/timothy_tests/quick_tests/test_yaffs_open_EINVAL.c @@ -21,8 +21,10 @@ int test_yaffs_open_EINVAL(void){ handle=yaffs_open(FILE_PATH, 255,FILE_MODE); if (handle==-1){ error_code=yaffs_get_error(); - //printf("EEXIST def %d, Error code %d\n",(- EEXIST),error_code); - if (abs(error_code)== EINVAL){ + if (abs(error_code)== EEXIST){ /* yaffs open does not check the mode. + so yaffs open does not return EINVAL. + This causes the error EEXIST to happen instead + because both O_CREAT and O_EXCL are set */ return 1; } else {