D10820: Send slave's polkit authorization status to the host

David Faure noreply at phabricator.kde.org
Thu Mar 1 07:06:34 UTC 2018


dfaure requested changes to this revision.
dfaure added inline comments.
This revision now requires changes to proceed.

INLINE COMMENTS

> slavebase.cpp:153
> +            if (action.status() != KAuth::Action::AuthorizedStatus) {
> +                m_TempAuth.remove(actId);
> +            }

This detaches (makes a copy of the list) because we're iterating over that same list.
This should use iterators, with the usual it = container.remove(it)
(or an algorithm, but this falls into the ugly erase(remove_if()) case).

Cleaning up in a "has" method is a little unexpected anyway.
Maybe it's simpler to make this one a find_if, and clean up elsewhere? Just a thought.

> slavebase.cpp:555
>      }
>      send(MSG_SLAVE_STATUS, data);
>  }

make that _V2, with << d->onHold rather than if(d->onHold), see other RR.

REPOSITORY
  R241 KIO

REVISION DETAIL
  https://phabricator.kde.org/D10820

To: chinmoyr, dfaure
Cc: #frameworks, michaelh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180301/0ee0bde6/attachment.html>


More information about the Kde-frameworks-devel mailing list