comparison src/audlegacy/playlist.c @ 4862:7ec3621a9f9b

We only need the results of the stat once, do not bother with a variable at all. From code analysis, unique ID uYRsrf.
author Tony Vroon <chainsaw@gentoo.org>
date Sun, 19 Apr 2009 23:26:48 +0100
parents 23cc350969e6
children 4cfb5217560a
comparison
equal deleted inserted replaced
4861:05baced7e1e7 4862:7ec3621a9f9b
2188 PlaylistEntry * b) 2188 PlaylistEntry * b)
2189 { 2189 {
2190 struct stat buf; 2190 struct stat buf;
2191 time_t modtime; 2191 time_t modtime;
2192 2192
2193 gint rv; 2193 if (stat(a->filename, &buf) == 0) {
2194
2195
2196 rv = stat(a->filename, &buf);
2197
2198 if (rv == 0) {
2199 modtime = buf.st_mtime; 2194 modtime = buf.st_mtime;
2200 rv = stat(b->filename, &buf);
2201 2195
2202 if (stat(b->filename, &buf) == 0) { 2196 if (stat(b->filename, &buf) == 0) {
2203 if (buf.st_mtime == modtime) 2197 if (buf.st_mtime == modtime)
2204 return 0; 2198 return 0;
2205 else 2199 else