It did some odd things for unclear reasons. As this is one of the functions that gets changed when doing word-at-a-time compares, this is yet another of the "don't change any semantics, but clean things up so that subsequent patches don't get obscured by the cleanups".
Unified · Split
| @@ -54,18 +54,17 @@ extern struct dentry_stat_t dentry_stat; · 53 unmodified lines | ||
| 54 | 54 | static inline int dentry_cmp(const unsigned char *cs, size_t scount, |
| 55 | 55 | const unsigned char *ct, size_t tcount) |
| 56 | 56 | { |
| 57 | − int ret; | |
| 58 | 57 | if (scount != tcount) |
| 59 | 58 | return 1; |
| 59 | + | |
| 60 | 60 | do { |
| 61 | − ret = (*cs != *ct); | |
| 62 | − if (ret) | |
| 63 | − break; | |
| 61 | + if (*cs != *ct) | |
| 62 | + return 1; | |
| 64 | 63 | cs++; |
| 65 | 64 | ct++; |
| 66 | 65 | tcount--; |
| 67 | 66 | } while (tcount); |
| 68 | − return ret; | |
| 67 | + return 0; | |
| 69 | 68 | } |
| 70 | 69 | |
| 71 | 70 | /* Name hashing routines. Initial hash value */ |