Nothing earth shattering, just some minor tweaks.
#include "shared-forward.h" /* IWYU pragma: export */
typedef struct Context Context;
-typedef struct PartitionInfo PartitionInfo;
-typedef struct Resource Resource;
typedef struct Instance Instance;
typedef struct InstanceMetadata InstanceMetadata;
+typedef struct PartitionInfo PartitionInfo;
+typedef struct Resource Resource;
+typedef struct Transfer Transfer;
+typedef struct UpdateSet UpdateSet;
r = pattern_match(*p, s, &found);
if (r < 0)
return r;
- if (r > 0) {
+ if (r != PATTERN_MATCH_NO) {
if (ret) {
*ret = found;
found = (InstanceMetadata) INSTANCE_METADATA_NULL;
return log_oom();
r = pattern_match_many(rr->patterns, rel_joined_for_matching, &extracted_fields);
+ if (r < 0)
+ return log_error_errno(r, "Failed to match pattern: %m");
if (r == PATTERN_MATCH_RETRY) {
_cleanup_closedir_ DIR *subdir = NULL;
return r;
if (r == 0)
continue;
- }
- else if (r < 0)
- return log_error_errno(r, "Failed to match pattern: %m");
- else if (r == PATTERN_MATCH_NO)
+ } else if (r == PATTERN_MATCH_NO)
continue;
if (de->d_type == DT_DIR && m != S_IFDIR)