summaryrefslogtreecommitdiff
path: root/mac/sar/test/unit_test/ecos
diff options
context:
space:
mode:
authorlaranjeiro2007-11-22 10:30:16 +0000
committerlaranjeiro2007-11-22 10:30:16 +0000
commitc85043ef9db62ec760a64c4ae76d8c50bbfca149 (patch)
treed670c7fae23b8dd295b959b4120524041a10f2d6 /mac/sar/test/unit_test/ecos
parent2fb38e15b0c22df60f7a6fe7568d4240b9f9bcae (diff)
Update the hosts test for the SAR. (i.e. memory leaks)
git-svn-id: svn+ssh://pessac/svn/cesar/trunk@1032 017c9cb6-072f-447c-8318-d5b54f68fe89
Diffstat (limited to 'mac/sar/test/unit_test/ecos')
-rw-r--r--mac/sar/test/unit_test/ecos/src/sar_mf_function_test.c8
-rw-r--r--mac/sar/test/unit_test/ecos/src/segmentation_complete.c18
2 files changed, 13 insertions, 13 deletions
diff --git a/mac/sar/test/unit_test/ecos/src/sar_mf_function_test.c b/mac/sar/test/unit_test/ecos/src/sar_mf_function_test.c
index e0914d8ff8..fcd0121275 100644
--- a/mac/sar/test/unit_test/ecos/src/sar_mf_function_test.c
+++ b/mac/sar/test/unit_test/ecos/src/sar_mf_function_test.c
@@ -77,8 +77,8 @@ int main (void)
test_begin(test, "test MF 1, offset = 0")
{
test_fail_if (mf_get_type(pb1, 0) != (uint) mfh->type, "Type in MF 1 does not correspond");
- test_fail_if (mf_get_length(pb1, 0, true) != (uint) mfh->length + 1, "Pyaload Length in MF 1 does not correspond");
- test_fail_if (mf_get_length(pb1, 0, false) != (uint) mfh->length + 11, "Complete Length in MF 1 does not correspond");
+ test_fail_if (mf_get_length(pb1, 0, true) != (uint) (mfh->length + 1), "Pyaload Length in MF 1 does not correspond");
+ test_fail_if (mf_get_length(pb1, 0, false) != (uint) (mfh->length + 11), "Complete Length in MF 1 does not correspond");
test_fail_if (mf_get_ats(pb1, 0) != (uint) mfh->ats, "Ats does not correspond");
}
test_end;
@@ -125,11 +125,11 @@ int main (void)
test_begin(test, "two MF followed")
{
test_fail_if (mf_get_type(pb1, 0) != (uint)((sar_mf_mfh_t *)(pb1->data))->type, "Type Should correspond");
- test_fail_if (mf_get_length(pb1, 0, true) != (uint) ((sar_mf_mfh_t *)(pb1->data))->length + 1, "Length Should correspond");
+ test_fail_if (mf_get_length(pb1, 0, true) != (uint) (((sar_mf_mfh_t *)(pb1->data))->length + 1), "Length Should correspond");
test_fail_if (mf_get_ats(pb1, 0) != (uint) ((sar_mf_mfh_t *)(pb1->data))->ats, "Ats should correspond");
test_fail_if (mf_get_type(pb1, 283) != (uint) ((sar_mf_mfh_t *)(pb1->data + 283))->type, "Type Should correspond");
- test_fail_if (mf_get_length(pb1, 283, true) != (uint) ((sar_mf_mfh_t *)(pb1->data + 283))->length + 1, "Length Should correspond");
+ test_fail_if (mf_get_length(pb1, 283, true) != (uint) (((sar_mf_mfh_t *)(pb1->data + 283))->length + 1), "Length Should correspond");
test_fail_if (mf_get_ats(pb1, 283) != (uint) ((sar_mf_mfh_t *)(pb1->data + 283))->ats, "Ats should correspond");
}
test_end;
diff --git a/mac/sar/test/unit_test/ecos/src/segmentation_complete.c b/mac/sar/test/unit_test/ecos/src/segmentation_complete.c
index 49f5d6c1bf..90295620cf 100644
--- a/mac/sar/test/unit_test/ecos/src/segmentation_complete.c
+++ b/mac/sar/test/unit_test/ecos/src/segmentation_complete.c
@@ -76,7 +76,7 @@ void mfs_type1 (test_t test)
/**The test starts here*/
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, data_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) (u8 *) packet3, packet3_len, 0x12345678, data_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
@@ -127,7 +127,7 @@ void mfs_type2 (test_t test)
/**The test starts here*/
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, data_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, data_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
@@ -176,7 +176,7 @@ void mfs_type3 (test_t test)
/**The test starts here*/
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, mme_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, mme_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
@@ -223,12 +223,12 @@ void mfs_type1_two_MF (test_t test)
/**The test starts here*/
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, data_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, data_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, data_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, data_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
@@ -284,12 +284,12 @@ void mfs_type2_two_MF (test_t test)
/**The test starts here*/
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, data_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, data_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, data_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, data_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
@@ -342,11 +342,11 @@ void mfs_type3_two_MF (test_t test)
/**The test starts here*/
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, mme_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, mme_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);
/** Add the msdu to the sar. */
- sar_msdu_add (sar_ctx, packet3, packet3_len, 0x12345678, mme_mfs);
+ sar_msdu_add (sar_ctx, (u8 *) packet3, packet3_len, 0x12345678, mme_mfs);
/** Launch the sar with this msdu. */
sar_launch (sar_ctx);