]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/chips/stm25p/Stm25pLogP.nc
- Fix bug found by Guillermo De Cesco. The buffer pointer was not
[tinyos-2.x.git] / tos / chips / stm25p / Stm25pLogP.nc
index 192b01b3eefc7a622e9cceb60dae7859d7b3b029..d00dee0610f1ddcc356ef63694fc89e2dd9cecca 100644 (file)
@@ -290,7 +290,7 @@ implementation {
        read_addr &= ~BLOCK_MASK;
       }
       else {
-       buf = m_log_state[ client ].buf;
+       buf = m_log_state[ client ].buf + m_log_state[ client ].len - m_len;
        // truncate if record is shorter than requested length
        if ( m_log_info[ client ].remaining < m_len )
          len = m_log_info[ client ].remaining;