]> git.saurik.com Git - apple/dyld.git/blobdiff - unit-tests/test-cases/rpath-dlopen-leak/main.c
dyld-360.14.tar.gz
[apple/dyld.git] / unit-tests / test-cases / rpath-dlopen-leak / main.c
index b33ceca8e85b5df70d0f3ffe45bec2955c952de8..993ea2501923586339d7743c839dab6f78308602 100644 (file)
@@ -40,8 +40,11 @@ int main()
        
        // execute leaks command on myself
        char cmd[512];
        
        // execute leaks command on myself
        char cmd[512];
-       sprintf(cmd, "leaks %u\n", getpid());
-       system(cmd);
+       int result = system(cmd);
+       if ( result == EXIT_SUCCESS )
+               PASS("rpath-dlopen-leak");
+       else
+               FAIL("rpath-dlopen-leak");
                
        return EXIT_SUCCESS;
 }
                
        return EXIT_SUCCESS;
 }