From c6ac943216ed9b9583a6532c09321f53eb3c02e9 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sat, 8 Dec 2001 21:03:41 +0000 Subject: [PATCH] Clean up indentation. svn path=/trunk/; revision=4362 --- epan/packet.c | 38 +++++++++++++++++++------------------- packet-frame.c | 31 ++++++++++++++++--------------- 2 files changed, 35 insertions(+), 34 deletions(-) diff --git a/epan/packet.c b/epan/packet.c index 53b33f840b..a4c70dbe47 100644 --- a/epan/packet.c +++ b/epan/packet.c @@ -1,7 +1,7 @@ /* packet.c * Routines for packet disassembly * - * $Id: packet.c,v 1.52 2001/12/08 06:41:47 guy Exp $ + * $Id: packet.c,v 1.53 2001/12/08 21:00:42 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs @@ -152,24 +152,24 @@ init_all_protocols(void) /* Creates the top-most tvbuff and calls dissect_frame() */ void dissect_packet(epan_dissect_t *edt, union wtap_pseudo_header *pseudo_header, - const u_char *pd, frame_data *fd) + const u_char *pd, frame_data *fd) { - edt->pi.dl_src.type = AT_NONE; - edt->pi.dl_dst.type = AT_NONE; - edt->pi.net_src.type = AT_NONE; - edt->pi.net_dst.type = AT_NONE; - edt->pi.src.type = AT_NONE; - edt->pi.dst.type = AT_NONE; - edt->pi.ethertype = 0; - edt->pi.ipproto = 0; - edt->pi.ipxptype = 0; - edt->pi.in_error_pkt = FALSE; - edt->pi.ptype = PT_NONE; - edt->pi.srcport = 0; - edt->pi.destport = 0; - edt->pi.current_proto = ""; - edt->pi.p2p_dir = P2P_DIR_UNKNOWN; - edt->pi.private_data = NULL; + edt->pi.dl_src.type = AT_NONE; + edt->pi.dl_dst.type = AT_NONE; + edt->pi.net_src.type = AT_NONE; + edt->pi.net_dst.type = AT_NONE; + edt->pi.src.type = AT_NONE; + edt->pi.dst.type = AT_NONE; + edt->pi.ethertype = 0; + edt->pi.ipproto = 0; + edt->pi.ipxptype = 0; + edt->pi.in_error_pkt = FALSE; + edt->pi.ptype = PT_NONE; + edt->pi.srcport = 0; + edt->pi.destport = 0; + edt->pi.current_proto = ""; + edt->pi.p2p_dir = P2P_DIR_UNKNOWN; + edt->pi.private_data = NULL; edt->pi.fd = fd; edt->pi.pseudo_header = pseudo_header; @@ -178,7 +178,7 @@ dissect_packet(epan_dissect_t *edt, union wtap_pseudo_header *pseudo_header, TRY { edt->tvb = tvb_new_real_data(pd, fd->cap_len, fd->pkt_len, "Frame"); - /* Add this tvbuffer into the data_src list */ + /* Add this tvbuffer into the data_src list */ fd->data_src = g_slist_append( fd->data_src, edt->tvb); } CATCH(BoundsError) { diff --git a/packet-frame.c b/packet-frame.c index 231acab969..f3fee8f4b4 100644 --- a/packet-frame.c +++ b/packet-frame.c @@ -2,12 +2,11 @@ * * Top-most dissector. Decides dissector based on Wiretap Encapsulation Type. * - * $Id: packet-frame.c,v 1.13 2001/12/08 06:41:41 guy Exp $ + * $Id: packet-frame.c,v 1.14 2001/12/08 21:03:41 guy Exp $ * * Ethereal - Network traffic analyzer - * By Gerald Combs + * By Gerald Combs * Copyright 2000 Gerald Combs - * * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -124,11 +123,12 @@ dissect_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) 0, 0, pinfo->p2p_dir); } - if (show_file_off) { - proto_tree_add_int_format(fh_tree, hf_frame_file_off, tvb, - 0, 0, pinfo->fd->file_off, "File Offset: %ld (0x%lx)", - pinfo->fd->file_off, pinfo->fd->file_off); - } + if (show_file_off) { + proto_tree_add_int_format(fh_tree, hf_frame_file_off, tvb, + 0, 0, pinfo->fd->file_off, + "File Offset: %ld (0x%lx)", + pinfo->fd->file_off, pinfo->fd->file_off); + } } @@ -200,7 +200,7 @@ proto_register_frame(void) static gint *ett[] = { &ett_frame, }; - module_t *frame_module; + module_t *frame_module; wtap_encap_dissector_table = register_dissector_table("wtap_encap", "Wiretap encapsulation type", FT_UINT32, BASE_DEC); @@ -223,13 +223,14 @@ proto_register_frame(void) proto_set_cant_disable(proto_short); proto_set_cant_disable(proto_malformed); - /* Our preferences */ - frame_module = prefs_register_protocol(proto_frame, NULL); - prefs_register_bool_preference(frame_module, "show_file_off", - "Show File Offset", "Show File Offset", &show_file_off); + /* Our preferences */ + frame_module = prefs_register_protocol(proto_frame, NULL); + prefs_register_bool_preference(frame_module, "show_file_off", + "Show File Offset", "Show File Offset", &show_file_off); } void -proto_reg_handoff_frame(void){ - data_handle = find_dissector("data"); +proto_reg_handoff_frame(void) +{ + data_handle = find_dissector("data"); }