diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2010-04-22 14:38:12 +0100 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2010-04-22 14:38:12 +0100 |
commit | 3a12d05433153d5c7c84f85af6b5039fbcdd1d09 (patch) | |
tree | 2a5922d7681f5d21700d152dc09909c2809e28c9 /action.c | |
parent | f902c9ca4891dcd65fd1f4b8bba0d23c75451dcd (diff) | |
download | rsyslog-3a12d05433153d5c7c84f85af6b5039fbcdd1d09.tar.gz rsyslog-3a12d05433153d5c7c84f85af6b5039fbcdd1d09.tar.xz rsyslog-3a12d05433153d5c7c84f85af6b5039fbcdd1d09.zip |
solved alignment errors on Solaris Sparc
Diffstat (limited to 'action.c')
-rw-r--r-- | action.c | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -200,7 +200,7 @@ rsRetVal actionDestruct(action_t *pThis) /* message ptr cleanup */ for(i = 0 ; i < pThis->iNumTpls ; ++i) { - if(pThis->ppMsgs[i] != NULL) { + if(((uchar**)pThis->ppMsgs)[i] != NULL) { switch(pThis->eParamPassing) { case ACT_ARRAY_PASSING: #if 0 /* later! */ @@ -214,7 +214,7 @@ rsRetVal actionDestruct(action_t *pThis) #endif break; case ACT_STRING_PASSING: - d_free(pThis->ppMsgs[i]); + d_free(((uchar**)pThis->ppMsgs)[i]); break; default: assert(0); @@ -475,10 +475,10 @@ actionCallDoAction(action_t *pAction, msg_t *pMsg) for(i = 0 ; i < pAction->iNumTpls ; ++i) { switch(pAction->eParamPassing) { case ACT_STRING_PASSING: - CHKiRet(tplToString(pAction->ppTpl[i], pMsg, &(pAction->ppMsgs[i]), &(pAction->lenMsgs[i]))); + CHKiRet(tplToString(pAction->ppTpl[i], pMsg, &(((uchar**)pAction->ppMsgs)[i]), &(pAction->lenMsgs[i]))); break; case ACT_ARRAY_PASSING: - CHKiRet(tplToArray(pAction->ppTpl[i], pMsg, (uchar***) &(pAction->ppMsgs[i]))); + CHKiRet(tplToArray(pAction->ppTpl[i], pMsg, (uchar***) &(((uchar**)pAction->ppMsgs)[i]))); break; default:assert(0); /* software bug if this happens! */ } @@ -526,16 +526,16 @@ actionCallDoAction(action_t *pAction, msg_t *pMsg) finalize_it: /* cleanup */ for(i = 0 ; i < pAction->iNumTpls ; ++i) { - if(pAction->ppMsgs[i] != NULL) { + if(((uchar**)pAction->ppMsgs)[i] != NULL) { switch(pAction->eParamPassing) { case ACT_ARRAY_PASSING: iArr = 0; - while(((char **)pAction->ppMsgs[i])[iArr] != NULL) { - d_free(((char **)pAction->ppMsgs[i])[iArr++]); - ((char **)pAction->ppMsgs[i])[iArr++] = NULL; + while((((uchar***)pAction->ppMsgs)[i][iArr]) != NULL) { + d_free(((uchar ***)pAction->ppMsgs)[i][iArr++]); + ((uchar ***)pAction->ppMsgs)[i][iArr++] = NULL; } - d_free(pAction->ppMsgs[i]); - pAction->ppMsgs[i] = NULL; + d_free(((uchar**)pAction->ppMsgs)[i]); + ((uchar**)pAction->ppMsgs)[i] = NULL; break; case ACT_STRING_PASSING: break; |