Commit 2e554fca authored by Lev Walkin's avatar Lev Walkin

some english fixes

parent 47a6ae6b
...@@ -888,12 +888,10 @@ END ...@@ -888,12 +888,10 @@ END
main() routine shown in the Section~\ref{sec:A-Rectangle-Decoder}) main() routine shown in the Section~\ref{sec:A-Rectangle-Decoder})
by placing the following snippet of code \emph{before} encoding and/or by placing the following snippet of code \emph{before} encoding and/or
\emph{after} decoding the Rectangle type% \emph{after} decoding the Rectangle type%
\footnote{Placing the constraint checking code \emph{before} encoding helps \footnote{Placing the constraint checking code \emph{before encoding} helps
to make sure you know the data is correct and within constraints before to make sure the data is correct and within constraints before
sharing the data with anyone else. sharing the data with anyone else.
Placing the constraint checking code \emph{after decoding} helps to make sure
Placing the constraint checking code \emph{after} decoding, but before
any further action depending on the decoded data, helps to make sure
the application got the valid contents before making use of it.% the application got the valid contents before making use of it.%
}: }:
...@@ -902,7 +900,7 @@ int ret; /* Return value */ ...@@ -902,7 +900,7 @@ int ret; /* Return value */
char errbuf[128]; /* Buffer for error message */ char errbuf[128]; /* Buffer for error message */
size_t errlen = sizeof(errbuf); /* Size of the buffer */ size_t errlen = sizeof(errbuf); /* Size of the buffer */
/* ... here may go Rectangle %\emph{decoding}% code ... */ /* ... here goes the Rectangle %\emph{decoding}% code ... */
ret = asn_check_constraints(&asn_DEF_Rectangle, rectangle, errbuf, &errlen); ret = asn_check_constraints(&asn_DEF_Rectangle, rectangle, errbuf, &errlen);
/* assert(errlen < sizeof(errbuf)); // you may rely on that */ /* assert(errlen < sizeof(errbuf)); // you may rely on that */
...@@ -913,7 +911,7 @@ if(ret) { ...@@ -913,7 +911,7 @@ if(ret) {
/* exit(...); // Replace with appropriate action */ /* exit(...); // Replace with appropriate action */
} }
/* ... here may go Rectangle %\emph{encoding}% code ... */ /* ... here goes the Rectangle %\emph{encoding}% code ... */
\end{codesample} \end{codesample}
\item Compile the resulting C code as shown in the previous chapters. \item Compile the resulting C code as shown in the previous chapters.
\item Try to test the constraints checking code by assigning integer value \item Try to test the constraints checking code by assigning integer value
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment