projects
/
yaffs2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of ssh://www.aleph1.co.uk/home/aleph1/git/yaffs2
[yaffs2.git]
/
direct
/
timothy_tests
/
quick_tests
/
test_yaffs_truncate_EFBIG.c
diff --git
a/direct/timothy_tests/quick_tests/test_yaffs_truncate_EFBIG.c
b/direct/timothy_tests/quick_tests/test_yaffs_truncate_EFBIG.c
index dd7cc86b61bf6854078ab68a35210fe2c5ff9c9d..0d698654916f3fe3a1a108379d55e818bf781cbe 100644
(file)
--- a/
direct/timothy_tests/quick_tests/test_yaffs_truncate_EFBIG.c
+++ b/
direct/timothy_tests/quick_tests/test_yaffs_truncate_EFBIG.c
@@
-12,9
+12,10
@@
*/
#include "test_yaffs_truncate_EFBIG.h"
*/
#include "test_yaffs_truncate_EFBIG.h"
-static int handle
=0
;
+static int handle
= -1
;
-int test_yaffs_truncate_EFBIG(void){
+int test_yaffs_truncate_EFBIG(void)
+{
int error=0;
int output=0;
handle=test_yaffs_open();
int error=0;
int output=0;
handle=test_yaffs_open();
@@
-22,26
+23,24
@@
int test_yaffs_truncate_EFBIG(void){
output= yaffs_truncate("/yaffs2/foo",10000000000000000000000000000000000000000000 );
if (output<0){
error=yaffs_get_error();
output= yaffs_truncate("/yaffs2/foo",10000000000000000000000000000000000000000000 );
if (output<0){
error=yaffs_get_error();
- if (abs(error)==EINVAL){
+ if (abs(error)==EINVAL){
/*in yaffs EINVAL is used instead of EFBIG */
return 1;
return 1;
- }
- else {
- printf("recieved a different error than expected\n");
+ } else {
+ print_message("received a different error than expected\n",2);
return -1;
}
return -1;
}
- }
- else{
- printf("truncated a file to a massive size\n");
+ } else{
+ print_message("truncated a file to a massive size\n",2);
return -1;
}
return -1;
}
- }
- else {
- printf("error opening file");
+ } else {
+ print_message("error opening file\n",2);
return -1;
}
}
return -1;
}
}
-int test_yaffs_truncate_EFBIG_clean(void){
+int test_yaffs_truncate_EFBIG_clean(void)
+{
return 1;
}
return 1;
}