[openrtm-users 03072] Is RTC::TimedStringSequence to bytestream conversion a well defined function?

2 個の投稿 / 0 new
最終投稿
athos
オフライン
Last seen: 6年 7ヶ月 前
登録日: 2014-07-10 17:28
[openrtm-users 03072] Is RTC::TimedStringSequence to bytestream conversion a well defined function?

Dear All,

I have the following problem. I generate some RTC::TimedStringSequence
data (say a1), then I serialize it into a byte stream (say b1) using
the cdrMemoryStream API. Then I convert this bytestream b1 back to a
RTC::TimedStringSequence variable (say a2): all is fine, the content
of a1 and that of b1 is the same as far as I can judge. But if I
convert a2 into a bytestream b2 again, then b1 and b2 differ
sometimes. Is this possible?

Valgrind says that some uninitialized memory area is copied into the
bytestreams: is this OK?

I can put together some minimal example, if needed.

Attila
_______________________________________________
openrtm-users mailing list
openrtm-users@openrtm.org
http://www.openrtm.org/mailman/listinfo/openrtm-users

未定義
gbiggs
オフライン
Last seen: 3年 7ヶ月 前
登録日: 2010-08-02 07:51
[openrtm-users 03073] Is RTC::TimedStringSequence to bytestream

Hi Attila,

It will be easier to investigate the behaviour you are seeing if you can
provide an example.

Geoff

On Wed, 23 Jul 2014 13:53:37 Attila Bern

athos
オフライン
Last seen: 6年 7ヶ月 前
登録日: 2014-07-10 17:28
[openrtm-users 03074] Is RTC::TimedStringSequence to bytestream

Dear Geoffrey (and those who read this),

I worked quite a bit to make up a self-contained example that shows the anomaly.

I have not completely succeeded.
The attached code, when compiled, does not show the phenomenon. However:
- the code I started with does not always show the phenomenon either
(it seems that it depends on the contents of the memory),
- if you compile and run the attached code with valgrind, it shows
that some uninitialized values are copied into the byte arrays at some
point.

One more remark: the byte array that I start with in the attached code
is obtained from a valid RTC::TimedStringSeq data.

I have linux 12.04, and g++ of version 4.6.3

Attila

2014-07-23 15:05 GMT+02:00 Geoffrey Biggs :
> Hi Attila,
>
> It will be easier to investigate the behaviour you are seeing if you can
> provide an example.
>
> Geoff
>
> On Wed, 23 Jul 2014 13:53:37 Attila Bern㙈﹀h wrote:
>> Dear All,
>>
>>
>> I have the following problem. I generate some RTC::TimedStringSequence
>> data (say a1), then I serialize it into a byte stream (say b1) using
>> the cdrMemoryStream API. Then I convert this bytestream b1 back to a
>> RTC::TimedStringSequence variable (say a2): all is fine, the content
>> of a1 and that of b1 is the same as far as I can judge. But if I
>> convert a2 into a bytestream b2 again, then b1 and b2 differ
>> sometimes. Is this possible?
>>
>> Valgrind says that some uninitialized memory area is copied into the
>> bytestreams: is this OK?
>>
>> I can put together some minimal example, if needed.
>>
>> Attila
>> _______________________________________________
>> openrtm-users mailing list
>> openrtm-users@openrtm.org
>> http://www.openrtm.org/mailman/listinfo/openrtm-users
>
> _______________________________________________
> openrtm-users mailing list
> openrtm-users@openrtm.org
> http://www.openrtm.org/mailman/listinfo/openrtm-users
>
> _______________________________________________
> openrtm-users mailing list
> openrtm-users@openrtm.org
> http://www.openrtm.org/mailman/listinfo/openrtm-users
>

コメントを投稿するにはログインまたはユーザー登録を行ってください

ダウンロード

最新バージョン

初めての方へ

Windows msi(インストーラ) パッケージ (サンプルの実行ができます。)

C++,Python,Java,
Toolsを含む
1.2.1-RELEASE

RTコンポーネントを開発するためには開発環境のインストールが必要です。詳細はダウンロードページ

統計

Webサイト統計
ユーザ数:1839
プロジェクト統計
RTコンポーネント297
RTミドルウエア28
ツール22
文書・仕様書1

Choreonoid

モーションエディタ/シミュレータ

OpenHRP3

動力学シミュレータ

OpenRTP

統合開発プラットフォーム

産総研RTC集

産総研が提供するRTC集

TORK

東京オープンソースロボティクス協会

DAQ-Middleware

ネットワーク分散環境でデータ収集用ソフトウェアを容易に構築するためのソフトウェア・フレームワーク