]> git.ipfire.org Git - thirdparty/libcgroup.git/commitdiff
libcgroup Test: fixed certain rejects
authorBalbir Singh <balbir@linux.vnet.ibm.com>
Wed, 17 Dec 2008 15:07:35 +0000 (15:07 +0000)
committerBalbir Singh <balbir@linux.vnet.ibm.com>
Wed, 17 Dec 2008 15:07:35 +0000 (15:07 +0000)
The following patch makes certain cleanups for the patchset to apply without
any rejects. However the lines of code are being changed in one of the next
patches.

Signed-off-by: Sudhir Kumar <skumar@linux.vnet.ibm.com>
git-svn-id: https://libcg.svn.sourceforge.net/svnroot/libcg/trunk@251 4f4bb910-9a46-0410-90c8-c897d4f1cd53

tests/libcgrouptest01.c

index 727e7d6bc6f1cda12feafce81f8bdc5094b2df6e..cca121031f28d366d0698d3fd21bcb8c58f8399f 100644 (file)
@@ -472,7 +472,7 @@ int main(int argc, char *argv[])
                        strcat(tasksfile, "/tasks");
                        strncpy(tasksfile2, mountpoint2, sizeof(mountpoint));
                        strcat(tasksfile2, "/tasks");
-                       if (check_task(tasksfile) || i-- && check_task(tasksfile2))
+                       if (check_task(tasksfile) || (i-- && check_task(tasksfile2)))
                                return -1;
                } else {
                        printf("Test[2:%2d]\tFAIL: cgroup_attach_task() ret: %d\n",\
@@ -573,7 +573,7 @@ int main(int argc, char *argv[])
                        strncpy(tasksfile2, mountpoint2, sizeof(tasksfile2));
                        strncat(tasksfile2, "/tasks", sizeof(tasksfile2));
 
-                       if (check_task(tasksfile) || i-- && check_task(tasksfile2))
+                       if (check_task(tasksfile) || (i-- && check_task(tasksfile2)))
                                return -1;
                } else {
                        printf("Test[2:%2d]\tFAIL: cgroup_attach_task() ret: %d\n",\
@@ -598,7 +598,7 @@ int main(int argc, char *argv[])
                        strncat(tasksfile2, "/memgroup1", sizeof(tasksfile2));
                        strncat(tasksfile2, "/tasks", sizeof(tasksfile2));
 
-                       if (check_task(tasksfile) || i-- && check_task(tasksfile2))
+                       if (check_task(tasksfile) || (i-- && check_task(tasksfile2)))
                                return -1;
                } else {
                        printf("Test[2:%2d]\tFAIL: cgroup_attach_task() ret: %d\n",\