diff options
author | Joel Rosdahl <joel@rosdahl.net> | 2012-01-08 13:30:51 +0100 |
---|---|---|
committer | Joel Rosdahl <joel@rosdahl.net> | 2012-01-08 13:30:51 +0100 |
commit | 90779f7dceea3e84e01c8908383a97ac1a7f8b45 (patch) | |
tree | 9f98b40ea7ff744deae939cfc6fd55d5a66aa7aa | |
parent | 01f0b62840259006f4bf1213568eaa6809ce29e2 (diff) | |
download | ccache-90779f7dceea3e84e01c8908383a97ac1a7f8b45.tar.gz |
while (1) -> while (true)
-rw-r--r-- | lockfile.c | 4 | ||||
-rw-r--r-- | stats.c | 4 | ||||
-rw-r--r-- | test/framework.c | 4 | ||||
-rw-r--r-- | util.c | 2 |
4 files changed, 7 insertions, 7 deletions
@@ -1,5 +1,5 @@ /* - * Copyright (C) 2010-2011 Joel Rosdahl + * Copyright (C) 2010-2012 Joel Rosdahl * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the Free @@ -43,7 +43,7 @@ lockfile_acquire(const char *path, unsigned staleness_limit) #endif unsigned to_sleep = 1000, slept = 0; /* Microseconds. */ - while (1) { + while (true) { free(my_content); my_content = format("%s:%d:%d", hostname, (int)getpid(), (int)time(NULL)); @@ -1,6 +1,6 @@ /* * Copyright (C) 2002-2004 Andrew Tridgell - * Copyright (C) 2009-2011 Joel Rosdahl + * Copyright (C) 2009-2012 Joel Rosdahl * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the Free @@ -105,7 +105,7 @@ parse_stats(struct counters *counters, const char *buf) long val; p = buf; - while (1) { + while (true) { val = strtol(p, &p2, 10); if (p2 == p) { break; diff --git a/test/framework.c b/test/framework.c index 53a8d60d..9abbb058 100644 --- a/test/framework.c +++ b/test/framework.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010 Joel Rosdahl + * Copyright (C) 2010, 2012 Joel Rosdahl * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the Free @@ -68,7 +68,7 @@ cct_run(suite_fn *suites, int verbose_output) for (suite = suites; *suite; suite++) { unsigned test_index = 0; - while (1) { + while (true) { test_index = (*suite)(test_index + 1); if (test_index == 0) { /* We have reached the end of the suite. */ @@ -900,7 +900,7 @@ gnu_getcwd(void) { unsigned size = 128; - while (1) { + while (true) { char *buffer = (char *)x_malloc(size); if (getcwd(buffer, size) == buffer) { return buffer; |