[pso] [Tema5][Win]No of rules

Alina Simion alina_simion2002 at yahoo.com
Tue Jun 10 12:57:01 EEST 2008


FW_LIST:
Am incercat copierea numarului de reguli in mai multe feluri:

if (!(to_copy=ExAllocatePoolWithTag(NonPagedPool, sizeof(int), 'lp1t')))
            {
                return STATUS_NO_MEMORY;
            }
to_copy[0] = nr;
irp->AssociatedIrp.SystemBuffer = to_copy;
pIrpStack->Parameters.DeviceIoControl.OutputBufferLength = sizeof(int);

sau

RtlCopyMemory(irp->AssociatedIrp.SystemBuffer, &nr, sizeof(int));
pIrpStack->Parameters.DeviceIoControl.OutputBufferLength = sizeof(int);

sau

((int*)irp->AssociatedIrp.SystemBuffer)[0] = nr;
pIrpStack->Parameters.DeviceIoControl.OutputBufferLength = sizeof(int);

Functia se termina cu STATUS_SUCCES, si totusi in ipnecklace sizeul obtinut este o 3408960
Ca urmare la al doilea DeviceIoControl, iese cu: Insufficient system resources exist to complete the requested service si pica testul No of rules.
S-a mai lovit cineva de problema asta?



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://cursuri.cs.pub.ro/pipermail/pso/attachments/20080610/c11e2599/attachment.htm 


More information about the pso mailing list