File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 4646#define TEST_CONTENT_DIR "/dev/shm/clip_store_content_dir_test"
4747
4848static int create_test_snip_fd (void ) {
49- shm_unlink (TEST_SNIP_FILE );
5049 int snip_fd = shm_open (TEST_SNIP_FILE , O_RDWR | O_CREAT | O_EXCL , 0600 );
5150 assert (snip_fd >= 0 );
5251 return snip_fd ;
@@ -104,7 +103,6 @@ static void remove_test_content_dir(const char *path) {
104103}
105104
106105static int create_test_content_dir_fd (void ) {
107- remove_test_content_dir (TEST_CONTENT_DIR );
108106 int ret = mkdir (TEST_CONTENT_DIR , 0700 );
109107 assert (ret == 0 );
110108 int dir_fd = open (TEST_CONTENT_DIR , O_RDONLY );
@@ -146,7 +144,9 @@ static void drop_teardown_test(struct clip_store *cs) {
146144 int ret = cs_destroy (cs );
147145 assert (ret == 0 );
148146 close (snip_fd );
147+ shm_unlink (TEST_SNIP_FILE );
149148 close (content_dir_fd );
149+ remove_test_content_dir (TEST_CONTENT_DIR );
150150}
151151
152152static void add_ten_snips (struct clip_store * cs ) {
You can’t perform that action at this time.
0 commit comments