cosmetics
[strongswan.git] / src / charon / encoding / parser.c
index 6e8bad5..d7caf70 100644 (file)
@@ -27,8 +27,7 @@
 
 #include "parser.h"
 
-#include <types.h>
-#include <definitions.h>
+#include <library.h>
 #include <daemon.h>
 #include <utils/linked_list.h>
 #include <encoding/payloads/encodings.h>
@@ -627,7 +626,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;                                  
+                               break;
                        }
                        case U_INT_32:
                        {
@@ -636,7 +635,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;          
+                               break;
                        }
                        case U_INT_64:
                        {
@@ -645,7 +644,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;  
+                               break;
                        }
                        case IKE_SPI:
                        {
@@ -654,7 +653,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;  
+                               break;
                        }
                        case RESERVED_BIT:
                        {
@@ -663,7 +662,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;  
+                               break;
                        }
                        case RESERVED_BYTE:
                        {
@@ -681,7 +680,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;  
+                               break;
                        }
                        case PAYLOAD_LENGTH:
                        {
@@ -691,7 +690,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        return PARSE_ERROR;
                                }
                                payload_length = *(u_int16_t*)(output + rule->offset);
-                               break;                                                  
+                               break;
                        }
                        case HEADER_LENGTH:
                        {
@@ -700,7 +699,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;                                                  
+                               break;
                        }
                        case SPI_SIZE:
                        {
@@ -710,7 +709,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        return PARSE_ERROR;
                                }
                                spi_size = *(u_int8_t*)(output + rule->offset);
-                               break;                                                  
+                               break;
                        }
                        case SPI:
                        {
@@ -719,7 +718,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;                                                  
+                               break;
                        }
                        case PROPOSALS:
                        {
@@ -729,7 +728,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;                                                  
+                               break;
                        }
                        case TRANSFORMS:
                        {
@@ -739,7 +738,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;                                                  
+                               break;
                        }
                        case TRANSFORM_ATTRIBUTES:
                        {
@@ -749,7 +748,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;                                                  
+                               break;
                        }
                        case CONFIGURATION_ATTRIBUTES:
                        {
@@ -759,7 +758,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }
-                               break;                                                  
+                               break;
                        }
                        case ATTRIBUTE_FORMAT:
                        {
@@ -790,7 +789,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                }
                                attribute_length = *(u_int16_t*)(output + rule->offset);
                                break;
-                       }                       
+                       }
                        case ATTRIBUTE_LENGTH_OR_VALUE:
                        {       
                                if (this->parse_uint16(this, rule_number, output + rule->offset) != SUCCESS) 
@@ -821,7 +820,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }               
-                               break;                  
+                               break;
                        }
                        case ID_DATA:
                        {
@@ -831,7 +830,7 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
                                }       
-                               break;                  
+                               break;
                        }
                        case AUTH_DATA:
                        {
@@ -840,8 +839,8 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                {
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
-                               }               
-                               break;                  
+                               }
+                               break;
                        }
                        case CERT_DATA:
                        {
@@ -850,8 +849,8 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                {
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
-                               }               
-                               break;                  
+                               }
+                               break;
                        }
                        case CERTREQ_DATA:
                        {
@@ -860,18 +859,18 @@ static status_t parse_payload(private_parser_t *this, payload_type_t payload_typ
                                {
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
-                               }               
-                               break;                  
+                               }
+                               break;
                        }
-                       case EAP_MESSAGE:
+                       case EAP_DATA:
                        {
                                size_t data_length = payload_length - EAP_PAYLOAD_HEADER_LENGTH;
                                if (this->parse_chunk(this, rule_number, output + rule->offset, data_length) != SUCCESS) 
                                {
                                        pld->destroy(pld);
                                        return PARSE_ERROR;
-                               }               
-                               break;                  
+                               }
+                               break;
                        }
                        case SPIS:
                        {