qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From astitc...@apache.org
Subject svn commit: r680828 - in /incubator/qpid/trunk/qpid/cpp/src/qpid: broker/ client/
Date Tue, 29 Jul 2008 20:26:47 GMT
Author: astitcher
Date: Tue Jul 29 13:26:46 2008
New Revision: 680828

URL: http://svn.apache.org/viewvc?rev=680828&view=rev
Log:
QPID-1198 (Partial): replace all uses of u_intX_t with uintX_t
Patches from Manuel Teira.
The u_int* versions are not available in the Sun header files.
In any case using only uint* is more consistent

Modified:
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.cpp
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.h
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStore.h
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.cpp
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.h
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.cpp
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.h
    incubator/qpid/trunk/qpid/cpp/src/qpid/broker/SessionAdapter.cpp
    incubator/qpid/trunk/qpid/cpp/src/qpid/client/SessionImpl.cpp

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.cpp
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.cpp?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.cpp (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.cpp Tue Jul 29 13:26:46
2008
@@ -43,11 +43,11 @@
 struct MessageDeliveryToken : BaseToken
 {
     const std::string destination;
-    const u_int8_t confirmMode;
-    const u_int8_t acquireMode;
+    const uint8_t confirmMode;
+    const uint8_t acquireMode;
     const bool isPreview;
 
-    MessageDeliveryToken(const std::string& d, u_int8_t c, u_int8_t a, bool p) : 
+    MessageDeliveryToken(const std::string& d, uint8_t c, uint8_t a, bool p) : 
         destination(d), confirmMode(c), acquireMode(a), isPreview(p) {}
 
     AMQFrame sendMethod(intrusive_ptr<Message> msg, DeliveryId /*id*/)
@@ -65,7 +65,7 @@
 }
 
 DeliveryToken::shared_ptr MessageDelivery::getMessageDeliveryToken(const std::string&
destination, 
-                                                                  u_int8_t confirmMode, u_int8_t
acquireMode)
+                                                                  uint8_t confirmMode, uint8_t
acquireMode)
 {
     return DeliveryToken::shared_ptr(new MessageDeliveryToken(destination, confirmMode, acquireMode,
false));
 }

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.h
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.h?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.h (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageDelivery.h Tue Jul 29 13:26:46 2008
@@ -41,8 +41,8 @@
 class MessageDelivery {
 public:
     static boost::shared_ptr<DeliveryToken> getMessageDeliveryToken(const std::string&
destination, 
-                                                                    u_int8_t confirmMode,

-                                                                    u_int8_t acquireMode);
+                                                                    uint8_t confirmMode,

+                                                                    uint8_t acquireMode);
 
     static void deliver(QueuedMessage& msg, framing::FrameHandler& out, 
                         DeliveryId deliveryTag, boost::shared_ptr<DeliveryToken> token,
uint16_t framesize);

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStore.h
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStore.h?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStore.h (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStore.h Tue Jul 29 13:26:46 2008
@@ -186,7 +186,7 @@
      *
      * @param queue the name of the queue to check for outstanding AIO
      */
-    virtual u_int32_t outstandingQueueAIO(const PersistableQueue& queue) = 0;
+    virtual uint32_t outstandingQueueAIO(const PersistableQueue& queue) = 0;
 
     
     virtual ~MessageStore(){}

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.cpp
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.cpp?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.cpp (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.cpp Tue Jul 29 13:26:46
2008
@@ -128,7 +128,7 @@
     TRANSFER_EXCEPTION(store->flush(queue));
 }
 
-u_int32_t MessageStoreModule::outstandingQueueAIO(const PersistableQueue& queue)
+uint32_t MessageStoreModule::outstandingQueueAIO(const PersistableQueue& queue)
 {
     TRANSFER_EXCEPTION(return store->outstandingQueueAIO(queue));
 }

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.h
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.h?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.h (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/MessageStoreModule.h Tue Jul 29 13:26:46
2008
@@ -71,7 +71,7 @@
     void dequeue(TransactionContext* ctxt,
                  const boost::intrusive_ptr<PersistableMessage>& msg,
                  const PersistableQueue& queue);
-    u_int32_t outstandingQueueAIO(const PersistableQueue& queue);
+    uint32_t outstandingQueueAIO(const PersistableQueue& queue);
     void flush(const qpid::broker::PersistableQueue& queue);
 	 
     ~MessageStoreModule();

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.cpp
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.cpp?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.cpp (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.cpp Tue Jul 29 13:26:46
2008
@@ -134,7 +134,7 @@
 {
 }
 
-u_int32_t NullMessageStore::outstandingQueueAIO(const PersistableQueue& )
+uint32_t NullMessageStore::outstandingQueueAIO(const PersistableQueue& )
 {
     return 0;
 }

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.h
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.h?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.h (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/NullMessageStore.h Tue Jul 29 13:26:46 2008
@@ -74,7 +74,7 @@
     virtual void dequeue(TransactionContext* ctxt,
                          const boost::intrusive_ptr<PersistableMessage>& msg,
                          const PersistableQueue& queue);
-    virtual u_int32_t outstandingQueueAIO(const PersistableQueue& queue);
+    virtual uint32_t outstandingQueueAIO(const PersistableQueue& queue);
     virtual void flush(const qpid::broker::PersistableQueue& queue);
     ~NullMessageStore(){}
 };

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/broker/SessionAdapter.cpp
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/broker/SessionAdapter.cpp?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/broker/SessionAdapter.cpp (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/broker/SessionAdapter.cpp Tue Jul 29 13:26:46 2008
@@ -369,7 +369,7 @@
     transfers.for_each(rejectOp);
 }
 
-void SessionAdapter::MessageHandlerImpl::flow(const std::string& destination, u_int8_t
unit, u_int32_t value)
+void SessionAdapter::MessageHandlerImpl::flow(const std::string& destination, uint8_t
unit, uint32_t value)
 {
     if (unit == 0) {
         //message
@@ -384,7 +384,7 @@
     
 }
     
-void SessionAdapter::MessageHandlerImpl::setFlowMode(const std::string& destination,
u_int8_t mode)
+void SessionAdapter::MessageHandlerImpl::setFlowMode(const std::string& destination,
uint8_t mode)
 {
     if (mode == 0) {
         //credit
@@ -589,7 +589,7 @@
 
 
 void SessionAdapter::DtxHandlerImpl::setTimeout(const Xid& xid,
-                                                u_int32_t timeout)
+                                                uint32_t timeout)
 {
     getBroker().getDtxManager().setTimeout(convert(xid), timeout);
 }

Modified: incubator/qpid/trunk/qpid/cpp/src/qpid/client/SessionImpl.cpp
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/cpp/src/qpid/client/SessionImpl.cpp?rev=680828&r1=680827&r2=680828&view=diff
==============================================================================
--- incubator/qpid/trunk/qpid/cpp/src/qpid/client/SessionImpl.cpp (original)
+++ incubator/qpid/trunk/qpid/cpp/src/qpid/client/SessionImpl.cpp Tue Jul 29 13:26:46 2008
@@ -301,22 +301,22 @@
 {
     AMQFrame header(content.getHeader());
     header.setFirstSegment(false);
-    u_int64_t data_length = content.getData().length();
+    uint64_t data_length = content.getData().length();
     if(data_length > 0){
         header.setLastSegment(false);
         handleOut(header);   
         /*Note: end of frame marker included in overhead but not in size*/
-        const u_int32_t frag_size = maxFrameSize - AMQFrame::frameOverhead(); 
+        const uint32_t frag_size = maxFrameSize - AMQFrame::frameOverhead(); 
 
         if(data_length < frag_size){
             AMQFrame frame(in_place<AMQContentBody>(content.getData()));
             frame.setFirstSegment(false);
             handleOut(frame);
         }else{
-            u_int32_t offset = 0;
-            u_int32_t remaining = data_length - offset;
+            uint32_t offset = 0;
+            uint32_t remaining = data_length - offset;
             while (remaining > 0) {
-                u_int32_t length = remaining > frag_size ? frag_size : remaining;
+                uint32_t length = remaining > frag_size ? frag_size : remaining;
                 string frag(content.getData().substr(offset, length));
                 AMQFrame frame(in_place<AMQContentBody>(frag));
                 frame.setFirstSegment(false);



Mime
View raw message