Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/ShExBy/shex_roo.../usr/include/arpa
File: tftp.h
/*
[0] Fix | Delete
* Copyright (c) 1983, 1993
[1] Fix | Delete
* The Regents of the University of California. All rights reserved.
[2] Fix | Delete
*
[3] Fix | Delete
* Redistribution and use in source and binary forms, with or without
[4] Fix | Delete
* modification, are permitted provided that the following conditions
[5] Fix | Delete
* are met:
[6] Fix | Delete
* 1. Redistributions of source code must retain the above copyright
[7] Fix | Delete
* notice, this list of conditions and the following disclaimer.
[8] Fix | Delete
* 2. Redistributions in binary form must reproduce the above copyright
[9] Fix | Delete
* notice, this list of conditions and the following disclaimer in the
[10] Fix | Delete
* documentation and/or other materials provided with the distribution.
[11] Fix | Delete
* 4. Neither the name of the University nor the names of its contributors
[12] Fix | Delete
* may be used to endorse or promote products derived from this software
[13] Fix | Delete
* without specific prior written permission.
[14] Fix | Delete
*
[15] Fix | Delete
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
[16] Fix | Delete
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
[17] Fix | Delete
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
[18] Fix | Delete
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
[19] Fix | Delete
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
[20] Fix | Delete
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
[21] Fix | Delete
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
[22] Fix | Delete
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
[23] Fix | Delete
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
[24] Fix | Delete
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
[25] Fix | Delete
* SUCH DAMAGE.
[26] Fix | Delete
*
[27] Fix | Delete
* @(#)tftp.h 8.1 (Berkeley) 6/2/93
[28] Fix | Delete
*/
[29] Fix | Delete
[30] Fix | Delete
#ifndef _ARPA_TFTP_H
[31] Fix | Delete
#define _ARPA_TFTP_H 1
[32] Fix | Delete
[33] Fix | Delete
/*
[34] Fix | Delete
* Trivial File Transfer Protocol (IEN-133)
[35] Fix | Delete
*/
[36] Fix | Delete
#define SEGSIZE 512 /* data segment size */
[37] Fix | Delete
[38] Fix | Delete
/*
[39] Fix | Delete
* Packet types.
[40] Fix | Delete
*/
[41] Fix | Delete
#define RRQ 01 /* read request */
[42] Fix | Delete
#define WRQ 02 /* write request */
[43] Fix | Delete
#define DATA 03 /* data packet */
[44] Fix | Delete
#define ACK 04 /* acknowledgement */
[45] Fix | Delete
#define ERROR 05 /* error code */
[46] Fix | Delete
[47] Fix | Delete
struct tftphdr {
[48] Fix | Delete
short th_opcode; /* packet type */
[49] Fix | Delete
union {
[50] Fix | Delete
char tu_padding[3]; /* sizeof() compat */
[51] Fix | Delete
struct {
[52] Fix | Delete
union {
[53] Fix | Delete
unsigned short tu_block; /* block # */
[54] Fix | Delete
short tu_code; /* error code */
[55] Fix | Delete
} __attribute__ ((__packed__)) th_u3;
[56] Fix | Delete
char tu_data[0]; /* data or error string */
[57] Fix | Delete
} __attribute__ ((__packed__)) th_u2;
[58] Fix | Delete
char tu_stuff[0]; /* request packet stuff */
[59] Fix | Delete
} __attribute__ ((__packed__)) th_u1;
[60] Fix | Delete
} __attribute__ ((__packed__));
[61] Fix | Delete
[62] Fix | Delete
#define th_block th_u1.th_u2.th_u3.tu_block
[63] Fix | Delete
#define th_code th_u1.th_u2.th_u3.tu_code
[64] Fix | Delete
#define th_stuff th_u1.tu_stuff
[65] Fix | Delete
#define th_data th_u1.th_u2.tu_data
[66] Fix | Delete
#define th_msg th_u1.th_u2.tu_data
[67] Fix | Delete
[68] Fix | Delete
/*
[69] Fix | Delete
* Error codes.
[70] Fix | Delete
*/
[71] Fix | Delete
#define EUNDEF 0 /* not defined */
[72] Fix | Delete
#define ENOTFOUND 1 /* file not found */
[73] Fix | Delete
#define EACCESS 2 /* access violation */
[74] Fix | Delete
#define ENOSPACE 3 /* disk full or allocation exceeded */
[75] Fix | Delete
#define EBADOP 4 /* illegal TFTP operation */
[76] Fix | Delete
#define EBADID 5 /* unknown transfer ID */
[77] Fix | Delete
#define EEXISTS 6 /* file already exists */
[78] Fix | Delete
#define ENOUSER 7 /* no such user */
[79] Fix | Delete
[80] Fix | Delete
#endif /* arpa/tftp.h */
[81] Fix | Delete
[82] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function