Browse Source

[master] Adapt new function after merge

This function was introduced after the branch was created, but the
changes are the same as with other functions - pushing directly.
Michal 'vorner' Vaner 14 years ago
parent
commit
d622e35a3d
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/lib/dns/buffer.h

+ 2 - 2
src/lib/dns/buffer.h

@@ -416,10 +416,10 @@ public:
     /// \param data The 8-bit integer to be written into the buffer.
     /// \param data The 8-bit integer to be written into the buffer.
     /// \param pos The position in the buffer to write the data.
     /// \param pos The position in the buffer to write the data.
     void writeUint8At(uint8_t data, size_t pos) {
     void writeUint8At(uint8_t data, size_t pos) {
-        if (pos + sizeof(data) > data_.size()) {
+        if (pos + sizeof(data) > size_) {
             isc_throw(InvalidBufferPosition, "write at invalid position");
             isc_throw(InvalidBufferPosition, "write at invalid position");
         }
         }
-        data_[pos] = data;
+        buffer_[pos] = data;
     }
     }
 
 
     /// \brief Write an unsigned 16-bit integer in host byte order into the
     /// \brief Write an unsigned 16-bit integer in host byte order into the