# #
#############################################################################*/
+#include <assert.h>
#include <errno.h>
#include <fcntl.h>
#include <stdlib.h>
}
// Make the static analyzer happy which thinks this could be NULL
- if (!data) {
- r = -EINVAL;
- goto ERROR;
- }
+ assert(data);
// Format >= 6
if (likely(archive->format >= 6)) {
# #
#############################################################################*/
+#include <assert.h>
#include <errno.h>
#include <limits.h>
#include <stddef.h>
goto ERROR;
// Make the static analyzer happy
- if (!path)
- goto ERROR;
+ assert(path);
// Drop everything but the last segment
while (path->num_segments > 1) {
goto ERROR;
// Make the static analyzer happy
- if (!path)
- goto ERROR;
+ assert(path);
// Drop the last segment
r = pakfire_path_remove_segment(path, path->num_segments - 1);
goto ERROR;
// Make the static analyzer happy
- if (!root || !path)
- goto ERROR;
+ assert(root && path);
// Both paths must be absolute
if (!root->is_absolute || !path->is_absolute) {
return r;
// Make the static analyzer happy
- if (!path)
- return -EINVAL;
+ assert(path);
// Is this absolute?
r = path->is_absolute;
return r;
// Make the static analyzer happy
- if (!path)
- return -EINVAL;
+ assert(path);
// Make it absolute
path->is_absolute = 1;
# #
#############################################################################*/
+#include <assert.h>
#include <errno.h>
#include <fcntl.h>
#include <fts.h>
goto ERROR;
// Make the static analyzer happy
- if (!self)
- goto ERROR;
+ assert(self);
// Enabled
pakfire_repo_set_enabled(self, pakfire_config_get_bool(config, section, "enabled", 1));
}
// Make the static analyzer happy
- if (!self->appdata) {
- r = -ENOMEM;
- goto ERROR;
- }
+ assert(self->appdata);
// Update the subpriority
pakfire_repo_update_subpriority(self);