From 2e0b4a2c54479aa7fcd37bb8379efb6d3de308ff Mon Sep 17 00:00:00 2001 From: Jeff Sharkey Date: Fri, 13 Mar 2015 13:40:50 -0700 Subject: [PATCH] Follow NetlinkEvent refactoring. Change-Id: I130b250a663cdfb379def24583523d0287ec31dd --- DirectVolume.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/DirectVolume.cpp b/DirectVolume.cpp index 64d7744..6118453 100644 --- a/DirectVolume.cpp +++ b/DirectVolume.cpp @@ -136,10 +136,10 @@ int DirectVolume::handleBlockEvent(NetlinkEvent *evt) { for (it = mPaths->begin(); it != mPaths->end(); ++it) { if ((*it)->match(dp)) { /* We can handle this disk */ - int action = evt->getAction(); + NetlinkEvent::Action action = evt->getAction(); const char *devtype = evt->findParam("DEVTYPE"); - if (action == NetlinkEvent::NlActionAdd) { + if (action == NetlinkEvent::Action::kAdd) { int major = atoi(evt->findParam("MAJOR")); int minor = atoi(evt->findParam("MINOR")); char nodepath[255]; @@ -166,13 +166,13 @@ int DirectVolume::handleBlockEvent(NetlinkEvent *evt) { mVm->getBroadcaster()->sendBroadcast(ResponseCode::VolumeDiskInserted, msg, false); } - } else if (action == NetlinkEvent::NlActionRemove) { + } else if (action == NetlinkEvent::Action::kRemove) { if (!strcmp(devtype, "disk")) { handleDiskRemoved(dp, evt); } else { handlePartitionRemoved(dp, evt); } - } else if (action == NetlinkEvent::NlActionChange) { + } else if (action == NetlinkEvent::Action::kChange) { if (!strcmp(devtype, "disk")) { handleDiskChanged(dp, evt); } else {