Page MenuHomePhabricator

Fix undefined behavior in rpc/server.cpp
ClosedPublic

Authored by jasonbcox on Mar 1 2019, 00:55.

Details

Summary

Calling std::move() on command while dereferencing GetName() is undefined.

Test Plan

ninja check

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Mar 1 2019, 07:14
deadalnix requested changes to this revision.Mar 1 2019, 13:59
deadalnix added inline comments.
src/rpc/server.cpp
71 ↗(On Diff #7547)

You are introducing a copy here for no good reason.

This revision now requires changes to proceed.Mar 1 2019, 13:59
This revision is now accepted and ready to land.Mar 2 2019, 00:44
This revision was automatically updated to reflect the committed changes.