Skip to content

Commit

Permalink
Avoid a clang++ warning.
Browse files Browse the repository at this point in the history
git-svn-id: https://valelab.ucsf.edu/svn/micromanager2/trunk@12317 d0ab736e-dc22-4aeb-8dc9-08def0aa14fd
  • Loading branch information
mark committed Dec 5, 2013
1 parent 771d3af commit afcc1c0
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions MMCore/AppleHost.h
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,6 @@ static kern_return_t FindEthernetInterfaces(io_iterator_t *matchingServices)
// In this sample the iterator should contain just the primary interface.
static kern_return_t GetMACAddress(io_iterator_t intfIterator, UInt8 *MACAddress, UInt8 bufferSize)
{
io_object_t intfService;
io_object_t controllerService;
kern_return_t kernResult = KERN_FAILURE;

// Make sure the caller provided enough buffer space. Protect against buffer overflow problems.
Expand All @@ -160,8 +158,9 @@ static kern_return_t GetMACAddress(io_iterator_t intfIterator, UInt8 *MACAddress
bzero(MACAddress, bufferSize);

// IOIteratorNext retains the returned object, so release it when we're done with it.
while (intfService = IOIteratorNext(intfIterator))
while (io_object_t intfService = IOIteratorNext(intfIterator))
{
io_object_t controllerService;
CFTypeRef MACAddressAsCFData;

// IONetworkControllers can't be found directly by the IOServiceGetMatchingServices call,
Expand Down

0 comments on commit afcc1c0

Please sign in to comment.