diff options
author | David Barksdale <amatus.amongus@gmail.com> | 2013-06-18 23:46:15 +0000 |
---|---|---|
committer | David Barksdale <amatus.amongus@gmail.com> | 2013-06-18 23:46:15 +0000 |
commit | a5ec32f96c44672b83ddadfe6a9bfa750273333f (patch) | |
tree | 7412c5804a33c1643c773ad9d35c104d8d8d6fdf /src/util/test_disk.c | |
parent | ab47616dbca27ca5c9ccb40532a7b59ac9dcaad7 (diff) | |
download | gnunet-a5ec32f96c44672b83ddadfe6a9bfa750273333f.tar.gz gnunet-a5ec32f96c44672b83ddadfe6a9bfa750273333f.zip |
Removed GNUNET_DISK_get_blocks_available since it's not used and it would
be hard to port to emscripten.
Diffstat (limited to 'src/util/test_disk.c')
-rw-r--r-- | src/util/test_disk.c | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/src/util/test_disk.c b/src/util/test_disk.c index 804a870e5..7fc8618ce 100644 --- a/src/util/test_disk.c +++ b/src/util/test_disk.c | |||
@@ -86,7 +86,6 @@ testOpenClose () | |||
86 | { | 86 | { |
87 | struct GNUNET_DISK_FileHandle *fh; | 87 | struct GNUNET_DISK_FileHandle *fh; |
88 | uint64_t size; | 88 | uint64_t size; |
89 | long avail; | ||
90 | 89 | ||
91 | fh = GNUNET_DISK_file_open (".testfile", | 90 | fh = GNUNET_DISK_file_open (".testfile", |
92 | GNUNET_DISK_OPEN_READWRITE | | 91 | GNUNET_DISK_OPEN_READWRITE | |
@@ -102,27 +101,6 @@ testOpenClose () | |||
102 | return 1; | 101 | return 1; |
103 | GNUNET_break (0 == UNLINK (".testfile")); | 102 | GNUNET_break (0 == UNLINK (".testfile")); |
104 | 103 | ||
105 | /* test that avail goes down as we fill the disk... */ | ||
106 | GNUNET_log_skip (1, GNUNET_NO); | ||
107 | avail = GNUNET_DISK_get_blocks_available (".testfile"); | ||
108 | GNUNET_log_skip (0, GNUNET_NO); | ||
109 | fh = GNUNET_DISK_file_open (".testfile", | ||
110 | GNUNET_DISK_OPEN_READWRITE | | ||
111 | GNUNET_DISK_OPEN_CREATE, | ||
112 | GNUNET_DISK_PERM_USER_WRITE | | ||
113 | GNUNET_DISK_PERM_USER_READ); | ||
114 | GNUNET_assert (GNUNET_NO == GNUNET_DISK_handle_invalid (fh)); | ||
115 | while ((avail == GNUNET_DISK_get_blocks_available (".testfile")) && | ||
116 | (avail != -1)) | ||
117 | if (16 != GNUNET_DISK_file_write (fh, "HelloWorld123456", 16)) | ||
118 | { | ||
119 | GNUNET_DISK_file_close (fh); | ||
120 | GNUNET_break (0 == UNLINK (".testfile")); | ||
121 | return 1; | ||
122 | } | ||
123 | GNUNET_DISK_file_close (fh); | ||
124 | GNUNET_break (0 == UNLINK (".testfile")); | ||
125 | |||
126 | return 0; | 104 | return 0; |
127 | } | 105 | } |
128 | 106 | ||