<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'><div dir='ltr'>
Hi, i m writing a module2 for freeradius 2.1.10 on linux 2.6.18-194.el5PAE.<br>
this is the code:<br>
<br>
vp = pairfind(request->packet->vps,<div id=":8i"><wbr>PW_USER_NAME);<br>
DEBUG("Found username = %s",vp->data.strvalue);<br>
<br>
// create and add the cleartext-password<br>
vp_clear_password = pairmake("Cleartext-password",<wbr>"smart",T_OP_SET);<br>
pairadd(&request->config_<wbr>items, vp_clear_password);<br>
<br>
// create and add the callback-id<br>
vp = pairmake("callback-id","<wbr>0702005010701059",T_OP_SET);<br>
pairadd(&request->reply->vps,<wbr>vp);<br>
<br>
<br>
but the pairfind is giving segmentation fault:<br>
<br>
Program received signal SIGSEGV, Segmentation fault.<br>
0x00b2879b in authorize (instance=0x8184460, request=0x81bbc68) at ../main.c:135<br>
135             vp = pairfind(request->packet->vps,<wbr>PW_USER_NAME);<br>
<br>
<br>
I have no idea what the problem is.<br>
What is the different between pairmake and radius_paircreate ?<br>
when am i supposed to use pairfree ?<br>
please let me know what the problem is.<br>
thanks!!<br>
</div>                                      </div></body>
</html>