~alan-griffiths/mir/remove-force_requests_to_complete

« back to all changes in this revision

Viewing changes to src/client/rpc/mir_socket_rpc_channel.cpp

  • Committer: Alan Griffiths
  • Date: 2014-02-06 11:51:51 UTC
  • mfrom: (1365.2.15 mir1)
  • Revision ID: alan@octopull.co.uk-20140206115151-gojji6b95vhn581k
mergeĀ lp:~alan-griffiths/mir/SwitchingBundle-controls-completion-of-client_acquire-without-blocking

Show diffs side-by-side

added added

removed removed

Lines of Context:
143
143
    if (!disconnected.load())
144
144
    {
145
145
        auto surface = dynamic_cast<mir::protobuf::Surface*>(response);
 
146
        mir::protobuf::Screencast* screencast{nullptr};
146
147
        if (surface)
147
148
        {
148
149
            surface->clear_fd();
157
158
                rpc_report->file_descriptors_received(*response, fds);
158
159
            }
159
160
        }
 
161
        else
 
162
        {
 
163
            screencast = dynamic_cast<mir::protobuf::Screencast*>(response);
 
164
        }
160
165
 
161
166
        auto buffer = dynamic_cast<mir::protobuf::Buffer*>(response);
162
167
        if (!buffer)
163
168
        {
164
169
            if (surface && surface->has_buffer())
165
170
                buffer = surface->mutable_buffer();
 
171
            else if (screencast && screencast->has_buffer())
 
172
                buffer = screencast->mutable_buffer();
166
173
        }
167
174
 
168
175
        if (buffer)