LENGTH is not anymore available
authorJan Hutter <jhutter@hsr.ch>
Mon, 14 Nov 2005 10:13:49 +0000 (10:13 -0000)
committerJan Hutter <jhutter@hsr.ch>
Mon, 14 Nov 2005 10:13:49 +0000 (10:13 -0000)
Source/charon/generator.c

index 997c556..30ca74c 100644 (file)
@@ -469,8 +469,13 @@ static status_t generate_payload (private_generator_t *this,payload_t *payload)
                                status = this->generate_flag(this,rules[i].offset);
                                break;
                        }
-                       case LENGTH:
-                               /* length is generated like an U_INT_32 */
+                       case PAYLOAD_LENGTH:
+                               /* payload length is generated like an U_INT_16 */
+                               status = this->generate_u_int_type(this,U_INT_16,rules[i].offset);
+                               break;
+
+                       case HEADER_LENGTH:
+                               /* header length is generated like an U_INT_32 */
                                status = this->generate_u_int_type(this,U_INT_32,rules[i].offset);
                                break;
                        case SPI_SIZE: