Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 3911 → Rev 3912

/branches/network/uspace/srv/net/structures/measured_strings.c
1,5 → 1,5
/*
* Copyright (c) 2008 Lukas Mejdrech
* Copyright (c) 2009 Lukas Mejdrech
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
31,7 → 31,7
*/
 
/** @file
* A character string with measured length implementation file.
* Character string with measured length implementation.
* @see measured_strings.h
*/
 
52,7 → 52,7
* @param strings The measured strings array to be processed. Input parameter.
* @param count The measured strings array size. Input parameter.
* @returns The computed sizes array.
* @returns NULL if there is no memory left.
* @returns NULL if there is not enough memory left.
*/
size_t * prepare_lengths( const measured_string_ref strings, size_t count );
 
91,7 → 91,7
free( lengths );
return EINVAL;
}
if( ERROR_OCCURED( ipc_data_write_finalize( callid, lengths, sizeof( size_t ) * ( count + 1 )))){
if( ERROR_OCCURRED( ipc_data_write_finalize( callid, lengths, sizeof( size_t ) * ( count + 1 )))){
free( lengths );
return ERROR_CODE;
}
146,7 → 146,7
free( lengths );
return EINVAL;
}
if( ERROR_OCCURED( ipc_data_read_finalize( callid, lengths, sizeof( size_t ) * ( count + 1 )))){
if( ERROR_OCCURRED( ipc_data_read_finalize( callid, lengths, sizeof( size_t ) * ( count + 1 )))){
free( lengths );
return ERROR_CODE;
}
175,7 → 175,7
}
lengths = ( size_t * ) malloc( sizeof( size_t ) * ( count + 1 ));
if( ! lengths ) return ENOMEM;
if( ERROR_OCCURED( ipc_data_read_start( phone, lengths, sizeof( size_t ) * ( count + 1 )))){
if( ERROR_OCCURRED( ipc_data_read_start( phone, lengths, sizeof( size_t ) * ( count + 1 )))){
free( lengths );
return ERROR_CODE;
}
215,7 → 215,7
}
lengths = prepare_lengths( strings, count );
if( ! lengths ) return ENOMEM;
if( ERROR_OCCURED( ipc_data_write_start( phone, lengths, sizeof( size_t ) * ( count + 1 )))){
if( ERROR_OCCURRED( ipc_data_write_start( phone, lengths, sizeof( size_t ) * ( count + 1 )))){
free( lengths );
return ERROR_CODE;
}