Merge pull request #2175 from cgwalters/coverity-2020.5
Two small Coverity fixes
This commit is contained in:
commit
c61ff03304
|
|
@ -436,8 +436,9 @@ ensure_idle_queued (OtPullData *pull_data)
|
|||
idle_src = g_idle_source_new ();
|
||||
g_source_set_callback (idle_src, idle_worker, pull_data, NULL);
|
||||
g_source_attach (idle_src, pull_data->main_context);
|
||||
g_source_unref (idle_src);
|
||||
pull_data->idle_src = idle_src;
|
||||
/* Ownership is transferred to pull_data */
|
||||
g_source_unref (idle_src);
|
||||
}
|
||||
|
||||
typedef struct {
|
||||
|
|
|
|||
|
|
@ -101,10 +101,9 @@ sysroot_is_configured_ro (const char *sysroot)
|
|||
bool ret = false;
|
||||
char *line = NULL;
|
||||
size_t len = 0;
|
||||
ssize_t nread;
|
||||
/* Note getline() will reuse the previous buffer */
|
||||
bool in_sysroot = false;
|
||||
while ((nread = getline (&line, &len, f)) != -1)
|
||||
while (getline (&line, &len, f) != -1)
|
||||
{
|
||||
/* This is an awful hack to avoid depending on GLib in the
|
||||
* initramfs right now.
|
||||
|
|
|
|||
Loading…
Reference in New Issue