forked from Imagelibrary/rtems
Merged from 4.5.0-beta3a
This commit is contained in:
@@ -21,10 +21,26 @@
|
||||
|
||||
#include "system.h"
|
||||
|
||||
#define MESSAGE_SIZE (sizeof(long) * 4)
|
||||
|
||||
void Fill_buffer(
|
||||
char *source,
|
||||
long *buffer
|
||||
)
|
||||
{
|
||||
char *p;
|
||||
int i;
|
||||
/*
|
||||
memcpy( buffer, source, 16 );
|
||||
*/
|
||||
p = source;
|
||||
for ( i=0 ; i<MESSAGE_SIZE ; i++ ) {
|
||||
buffer[i] = *p++;
|
||||
buffer[i] <<= 8;
|
||||
buffer[i] |= *p++;
|
||||
buffer[i] <<= 8;
|
||||
buffer[i] |= *p++;
|
||||
buffer[i] <<= 8;
|
||||
buffer[i] |= *p++;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user