2N/A * The contents of this file are subject to the terms of the 2N/A * Common Development and Distribution License (the "License"). 2N/A * You may not use this file except in compliance with the License. 2N/A * See the License for the specific language governing permissions 2N/A * and limitations under the License. 2N/A * When distributing Covered Code, include this CDDL HEADER in each 2N/A * If applicable, add the following below this CDDL HEADER, with the 2N/A * fields enclosed by brackets "[]" replaced with your own identifying 2N/A * information: Portions Copyright [yyyy] [name of copyright owner] 2N/A * Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved. 2N/A /* where to add ? */ 2N/A /* add the packet object in the end of list */ 2N/A /* if prev is NULL it's the first object in the list */ 2N/A for (i = 0;
buf[i] !=
'\0'; i++) {
2N/A /* ignore all comments */ 2N/A /* find the names */ 2N/A /* check the last remaining item */ 2N/A /* populate segment_t */ 2N/A /* populate section_t */ 2N/A /* read section header layout */ 2N/A /* size = section layout + total sizeof segment header */ 2N/A /* segment header buffer */ 2N/A /* read segment header */ 2N/A /* copy section header layout */ 2N/A /* copy segment header layout */ 2N/A /* bug fix for frutool */ 2N/A /* populate section_t */ 2N/A /* traverse the packet object list for all the tags and payload */ 2N/A return (
crc);
/* computed crc */ 2N/A /* section hash object */ 2N/A /* don't change this */ 2N/A /* section hash object */ 2N/A /* valid segment header b'cos crc8 already validated */ 2N/A /* segment hash object */ 2N/A /* packet hash object */ 2N/A /* verify payload length */ 2N/A /* lookup for container hash object */ 2N/A /* points to section object list */ 2N/A /* traverse section object list */ 2N/A /* traverse segment hash object in the section */ 2N/A /* object handle of the segment hash object */ 2N/A /* going to free section hash object, relink the hash object */ 2N/A /* free container hash object */