plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 1 | /* |
| 2 | * |
| 3 | * Copyright (c) International Business Machines Corp., 2001 |
| 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation; either version 2 of the License, or |
| 8 | * (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See |
| 13 | * the GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this program; if not, write to the Free Software |
Wanlong Gao | 4548c6c | 2012-10-19 18:03:36 +0800 | [diff] [blame] | 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 18 | */ |
| 19 | |
| 20 | /* |
| 21 | * NAME |
| 22 | * waitpid12.c |
subrata_modak | bdbaec5 | 2009-02-26 12:14:51 +0000 | [diff] [blame] | 23 | * |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 24 | * DESCRIPTION |
| 25 | * Tests to see if pid's returned from fork and waitpid are same |
subrata_modak | bdbaec5 | 2009-02-26 12:14:51 +0000 | [diff] [blame] | 26 | * |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 27 | * ALGORITHM |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 28 | * Check proper functioning of waitpid with pid = -1 and arg = WNOHANG |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 29 | * |
| 30 | * USAGE: <for command-line> |
| 31 | * waitpid12 [-c n] [-t] |
| 32 | * where, -c n : Run n copies concurrently. |
| 33 | * -t : Turn on syscall timing. |
| 34 | * |
| 35 | * History |
| 36 | * 07/2001 John George |
| 37 | * -Ported |
robbiew | 112db7a | 2002-04-25 15:57:02 +0000 | [diff] [blame] | 38 | * 04/2002 wjhuie sigset testx for SIG_ERR not < 0, TPASS|TFAIL issued |
robbiew | 4644c7e | 2002-04-26 14:33:32 +0000 | [diff] [blame] | 39 | * 04/2002 wjhuie sigset cleanups |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 40 | * |
| 41 | * Restrictions |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 42 | * None |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 43 | */ |
| 44 | |
| 45 | #include <sys/types.h> |
| 46 | #include <signal.h> |
| 47 | #include <errno.h> |
| 48 | #include <sys/wait.h> |
Garrett Cooper | e8530df | 2010-12-21 11:37:57 -0800 | [diff] [blame] | 49 | #include "test.h" |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 50 | |
| 51 | #define MAXKIDS 8 |
| 52 | |
| 53 | char *TCID = "waitpid12"; |
| 54 | int TST_TOTAL = 1; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 55 | |
robbiew | 3d5c735 | 2003-01-13 17:49:51 +0000 | [diff] [blame] | 56 | volatile int intintr; |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 57 | static void setup(void); |
| 58 | static void cleanup(void); |
| 59 | static void inthandlr(); |
| 60 | static void wait_for_parent(void); |
| 61 | static void do_exit(void); |
| 62 | static void setup_sigint(void); |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 63 | #ifdef UCLINUX |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 64 | static void do_exit_uclinux(void); |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 65 | #endif |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 66 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 67 | static int fail; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 68 | |
plars | 74948ad | 2002-11-14 16:16:14 +0000 | [diff] [blame] | 69 | int main(int argc, char **argv) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 70 | { |
Cyril Hrubis | 0b9589f | 2014-05-27 17:40:33 +0200 | [diff] [blame] | 71 | const char *msg; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 72 | |
| 73 | int kid_count, ret_val, status; |
plars | 74948ad | 2002-11-14 16:16:14 +0000 | [diff] [blame] | 74 | int i, j, k, found; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 75 | int group1, group2; |
| 76 | int fork_kid_pid[MAXKIDS], wait_kid_pid[MAXKIDS]; |
| 77 | int pid; |
| 78 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 79 | msg = parse_opts(argc, argv, NULL, NULL); |
| 80 | if (msg != NULL) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 81 | tst_brkm(TBROK, NULL, "OPTION PARSING ERROR - %s", msg); |
Garrett Cooper | 2c28215 | 2010-12-16 00:55:50 -0800 | [diff] [blame] | 82 | |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 83 | #ifdef UCLINUX |
| 84 | maybe_run_child(&do_exit_uclinux, ""); |
| 85 | #endif |
| 86 | |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 87 | setup(); |
| 88 | |
Caspar Zhang | d59a659 | 2013-03-07 14:59:12 +0800 | [diff] [blame] | 89 | tst_count = 0; |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 90 | fail = 0; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 91 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 92 | /* |
| 93 | * Need to have test run from child as test driver causes |
| 94 | * test to be a session leader and setpgrp fails. |
| 95 | */ |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 96 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 97 | pid = FORK_OR_VFORK(); |
| 98 | if (pid > 0) { |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 99 | waitpid(pid, &status, 0); |
| 100 | if (WEXITSTATUS(status) != 0) { |
| 101 | tst_resm(TFAIL, "child returned bad status"); |
| 102 | fail = 1; |
| 103 | } |
| 104 | if (fail) |
| 105 | tst_resm(TFAIL, "%s FAILED", TCID); |
| 106 | else |
| 107 | tst_resm(TPASS, "%s PASSED", TCID); |
| 108 | cleanup(); |
| 109 | tst_exit(); |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 110 | } else if (pid < 0) { |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 111 | tst_brkm(TBROK, cleanup, "fork failed"); |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 112 | } |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 113 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 114 | /* |
| 115 | * Set up to catch SIGINT. The kids will wait till a SIGINT |
| 116 | * has been received before they proceed. |
| 117 | */ |
| 118 | setup_sigint(); |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 119 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 120 | group1 = getpgrp(); |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 121 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 122 | for (kid_count = 0; kid_count < MAXKIDS; kid_count++) { |
| 123 | if (kid_count == (MAXKIDS / 2)) |
| 124 | group2 = setpgrp(); |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 125 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 126 | intintr = 0; |
| 127 | ret_val = FORK_OR_VFORK(); |
| 128 | if (ret_val == 0) { |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 129 | #ifdef UCLINUX |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 130 | if (self_exec(argv[0], "") < 0) |
| 131 | tst_resm(TFAIL, "self_exec kid %d " |
| 132 | "failed", kid_count); |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 133 | #else |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 134 | do_exit(); |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 135 | #endif |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 136 | } |
| 137 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 138 | if (ret_val < 0) |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 139 | tst_resm(TFAIL | TERRNO, "forking kid %d failed", |
| 140 | kid_count); |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 141 | |
| 142 | /* parent */ |
| 143 | fork_kid_pid[kid_count] = ret_val; |
| 144 | } |
| 145 | |
| 146 | /* Check that waitpid with WNOHANG returns zero */ |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 147 | ret_val = waitpid(0, &status, WNOHANG); |
| 148 | if (ret_val != 0) { |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 149 | tst_resm(TFAIL, "Waitpid returned wrong value"); |
| 150 | tst_resm(TFAIL, "Expected 0 got %d", ret_val); |
| 151 | fail = 1; |
| 152 | } |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 153 | #ifdef UCLINUX |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 154 | /* Give the kids a chance to setup SIGINT again, since this is |
| 155 | * cleared by exec(). |
| 156 | */ |
| 157 | sleep(3); |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 158 | #endif |
subrata_modak | 56207ce | 2009-03-23 13:35:39 +0000 | [diff] [blame] | 159 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 160 | /* Now send all the kids a SIGINT to tell them to proceed */ |
| 161 | for (i = 0; i < MAXKIDS; i++) |
| 162 | if (kill(fork_kid_pid[i], SIGINT) < 0) |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 163 | tst_resm(TFAIL | TERRNO, "killing child %d failed", i); |
Garrett Cooper | 2c28215 | 2010-12-16 00:55:50 -0800 | [diff] [blame] | 164 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 165 | /* |
| 166 | * Wait till all kids have terminated. Stash away their |
| 167 | * pid's in an array. |
| 168 | */ |
| 169 | kid_count = 0; |
| 170 | errno = 0; |
| 171 | sleep(2); |
| 172 | while (((ret_val = waitpid(0, &status, WNOHANG)) != -1) || |
| 173 | (errno == EINTR)) { |
| 174 | if ((ret_val == -1) || (ret_val == 0)) |
| 175 | continue; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 176 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 177 | if (!WIFEXITED(status)) { |
| 178 | tst_resm(TFAIL, "Child %d did not exit " |
| 179 | "normally", ret_val); |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 180 | fail = 1; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 181 | } else { |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 182 | if (WEXITSTATUS(status) != 3) { |
| 183 | tst_resm(TFAIL, "Child %d exited with " |
| 184 | "wrong status", ret_val); |
| 185 | tst_resm(TFAIL, "Expected 3 got %d", |
| 186 | WEXITSTATUS(status)); |
| 187 | fail = 1; |
| 188 | } |
| 189 | } |
| 190 | wait_kid_pid[kid_count++] = ret_val; |
| 191 | } |
| 192 | |
| 193 | /* |
| 194 | * Check that for every entry in the fork_kid_pid array, |
| 195 | * there is a matching pid in the wait_kid_pid array. If |
| 196 | * not, it's an error. |
| 197 | */ |
| 198 | for (i = 0; i < kid_count; i++) { |
| 199 | found = 0; |
| 200 | for (j = (MAXKIDS / 2); j < MAXKIDS; j++) { |
| 201 | if (fork_kid_pid[j] == wait_kid_pid[i]) { |
| 202 | found = 1; |
| 203 | break; |
| 204 | } |
| 205 | } |
| 206 | if (!found) { |
| 207 | tst_resm(TFAIL, "Did not find a wait_kid_pid " |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 208 | "for the fork_kid_pid of %d", wait_kid_pid[i]); |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 209 | for (k = 0; k < MAXKIDS; k++) |
| 210 | tst_resm(TFAIL, "fork_kid_pid[%d] = " |
| 211 | "%d", k, fork_kid_pid[k]); |
| 212 | for (k = 0; k < kid_count; k++) |
| 213 | tst_resm(TFAIL, "wait_kid_pid[%d] = " |
| 214 | "%d", k, wait_kid_pid[k]); |
| 215 | fail = 1; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 216 | } |
| 217 | } |
robbiew | aa01abd | 2003-03-27 18:39:24 +0000 | [diff] [blame] | 218 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 219 | if (kid_count != (MAXKIDS / 2)) { |
| 220 | tst_resm(TFAIL, "Wrong number of children waited on " |
| 221 | "for pid = 0"); |
| 222 | tst_resm(TFAIL, "Expected 4 got %d", kid_count); |
| 223 | fail = 1; |
| 224 | } |
| 225 | |
| 226 | /* Make sure can pickup children in a diff. process group */ |
| 227 | |
| 228 | kid_count = 0; |
| 229 | errno = 0; |
| 230 | while (((ret_val = waitpid(-(group1), &status, WNOHANG)) != |
| 231 | -1) || (errno == EINTR)) { |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 232 | if (ret_val == -1 || ret_val == 0) |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 233 | continue; |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 234 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 235 | if (!WIFEXITED(status)) { |
| 236 | tst_resm(TFAIL, "Child %d did not exit " |
| 237 | "normally", ret_val); |
| 238 | fail = 1; |
| 239 | } else { |
| 240 | if (WEXITSTATUS(status) != 3) { |
| 241 | tst_resm(TFAIL, "Child %d exited with " |
| 242 | "wrong status", ret_val); |
| 243 | tst_resm(TFAIL, "Expected 3 got %d", |
| 244 | WEXITSTATUS(status)); |
| 245 | fail = 1; |
| 246 | } |
| 247 | } |
| 248 | wait_kid_pid[kid_count++] = ret_val; |
| 249 | } |
| 250 | |
| 251 | /* |
| 252 | * Check that for every entry in the fork_kid_pid array, |
| 253 | * there is a matching pid in the wait_kid_pid array. If |
| 254 | * not, it's an error. |
| 255 | */ |
| 256 | for (i = 0; i < kid_count; i++) { |
| 257 | found = 0; |
| 258 | for (j = 0; j < (MAXKIDS / 2); j++) { |
| 259 | if (fork_kid_pid[j] == wait_kid_pid[i]) { |
| 260 | found = 1; |
| 261 | break; |
| 262 | } |
| 263 | } |
| 264 | if (!found) { |
| 265 | tst_resm(TFAIL, "Did not find a wait_kid_pid " |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 266 | "for the fork_kid_pid of %d", fork_kid_pid[j]); |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 267 | for (k = 0; k < MAXKIDS; k++) |
| 268 | tst_resm(TFAIL, "fork_kid_pid[%d] = " |
| 269 | "%d", k, fork_kid_pid[k]); |
| 270 | for (k = 0; k < kid_count; k++) |
| 271 | tst_resm(TFAIL, "wait_kid_pid[%d] = " |
| 272 | "%d", k, wait_kid_pid[k]); |
| 273 | fail = 1; |
| 274 | } |
| 275 | } |
| 276 | if (kid_count != (MAXKIDS / 2)) { |
| 277 | tst_resm(TFAIL, "Wrong number of children waited on " |
| 278 | "for pid = 0"); |
| 279 | tst_resm(TFAIL, "Expected 4 got %d", kid_count); |
| 280 | fail = 1; |
| 281 | } |
| 282 | |
| 283 | if (fail) |
| 284 | tst_resm(TFAIL, "Test FAILED"); |
| 285 | else |
| 286 | tst_resm(TPASS, "Test PASSED"); |
| 287 | |
| 288 | tst_exit(); |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 289 | } |
| 290 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 291 | static void setup_sigint(void) |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 292 | { |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 293 | if (signal(SIGINT, inthandlr) == SIG_ERR) |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 294 | tst_brkm(TFAIL | TERRNO, NULL, "signal SIGINT failed"); |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 295 | } |
| 296 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 297 | static void setup(void) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 298 | { |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 299 | tst_sig(FORK, DEF_HANDLER, cleanup); |
| 300 | |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 301 | TEST_PAUSE; |
| 302 | } |
| 303 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 304 | static void cleanup(void) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 305 | { |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 306 | } |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 307 | |
Mike Frysinger | c57fba5 | 2014-04-09 18:56:30 -0400 | [diff] [blame] | 308 | static void inthandlr(void) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 309 | { |
| 310 | intintr++; |
| 311 | } |
| 312 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 313 | static void wait_for_parent(void) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 314 | { |
| 315 | int testvar; |
| 316 | |
Garrett Cooper | c548a31 | 2011-03-04 02:12:05 -0800 | [diff] [blame] | 317 | while (!intintr) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 318 | testvar = 0; |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 319 | } |
| 320 | |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 321 | static void do_exit(void) |
plars | 865695b | 2001-08-27 22:15:12 +0000 | [diff] [blame] | 322 | { |
| 323 | wait_for_parent(); |
| 324 | exit(3); |
| 325 | } |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 326 | |
| 327 | #ifdef UCLINUX |
Wanlong Gao | ae24b14 | 2012-11-20 10:32:33 +0800 | [diff] [blame] | 328 | static void do_exit_uclinux(void) |
robbiew | d34d581 | 2005-07-11 22:28:09 +0000 | [diff] [blame] | 329 | { |
| 330 | setup_sigint(); |
| 331 | do_exit(); |
| 332 | } |
Garrett Cooper | 1e6f5a6 | 2010-12-19 09:58:10 -0800 | [diff] [blame] | 333 | #endif |