In HDLC, a zero is inserted after every five consecutive "ones" in order to resolve ambiguity about the location of delimiters. In this paper, we generalize the number "five" as an arbitrary positive integer

and study the impacts of

on the link utilization for a noiseless channel and on the reliability for a noisy channel. The entropy of the sequence after this generalized zero insertion is found for a noiseless channel. An expression for the optimal

that maximizes a quantity called the delimiter efficiency is also found in terms of the frame size. It is shown that

achieves a delimiter efficiency close (within 2 percent) to that achievable by the optimal

. For a noisy channel, the reliability of HDLC is derived. It is shown that the probability of an undetectable error in HDLC is dominated by the errors that propagate through a created flag or incorrect zero deletion, and is in the neighborhood of 10
-7for typical parameters. Increasing

by 8 is shown to improve the reliability by two orders of magnitude. It is proposed to use a two byte flag and a four byte frame check sequence to improve the reliability by seven orders of magnitude.