[haiku-commits] r34883 - haiku/trunk/headers/private/bluetooth

Author: oruizdorantes
Date: 2010-01-03 23:35:18 +0100 (Sun, 03 Jan 2010)
New Revision: 34883
Changeset: http://dev.haiku-os.org/changeset/34883/haiku

Modified:
   haiku/trunk/headers/private/bluetooth/PortListener.h
Log:
- sizeof(TYPE) would cause problems to instantiations of the class with void 
type

Modified: haiku/trunk/headers/private/bluetooth/PortListener.h
===================================================================
--- haiku/trunk/headers/private/bluetooth/PortListener.h        2010-01-03 
22:06:37 UTC (rev 34882)
+++ haiku/trunk/headers/private/bluetooth/PortListener.h        2010-01-03 
22:35:18 UTC (rev 34883)
@@ -51,15 +51,12 @@
        }
 
 
-       status_t Trigger(int32 code, TYPE* buffer, size_t size = 0)
+       status_t Trigger(int32 code, TYPE* buffer, size_t size)
        {
                if (buffer == NULL)
                        return B_ERROR;
 
-               if (size == 0)
-                       return write_port(fPort, code, buffer, sizeof(TYPE));
-               else
-                       return write_port(fPort, code, buffer, size);
+               return write_port(fPort, code, buffer, size);
        }
 
 


Other related posts:

  • » [haiku-commits] r34883 - haiku/trunk/headers/private/bluetooth - oliver . ruiz . dorantes