Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 144595 Details for
Bug 221056
dd_rhelp: "tail +N" deprecated
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
dd_rhelp patch
dd_rhelp.patch (text/plain), 4.29 KB, created by
Jason Farrell
on 2006-12-31 17:03:57 UTC
(
hide
)
Description:
dd_rhelp patch
Filename:
MIME Type:
Creator:
Jason Farrell
Created:
2006-12-31 17:03:57 UTC
Size:
4.29 KB
patch
obsolete
>--- /usr/bin/dd_rhelp 2006-11-09 20:41:26.000000000 -0500 >+++ dd_rhelp 2006-12-30 23:30:03.000000000 -0500 >@@ -518,7 +518,7 @@ > [ "$DEBUG" == "on" ] && echo "BAD !" >&2 > fi > >- path="$(dirname $(type -ap "$0" | "${TAIL}" -1))/dd_rescue" >+ path="$(dirname $(type -ap "$0" | "${TAIL}" -n -1))/dd_rescue" > > if [ -x "$path" ] ;then > version=$("$path" -V 2>&1 | grep "dd_rescue Version" | cut -f 3 -d " " | >@@ -664,7 +664,7 @@ > # new chunk doesn't overlap with current chunk > # Iterate, put current chunk in $goodchunk. > goodchunk="$(echo -en "$goodchunk\n$i")" >- parsechunk="$(echo "$parsechunk" | "${TAIL}" +2)" >+ parsechunk="$(echo "$parsechunk" | "${TAIL}" -n +2)" > continue > fi > >@@ -700,7 +700,7 @@ > if [ "$as_int" == "0" ] && [ "$ae_int" == "0" ] > then > # we forget about current chunk, and iterate. >- parsechunk=$(echo "$parsechunk" | "${TAIL}" +2) >+ parsechunk=$(echo "$parsechunk" | "${TAIL}" -n +2) > continue > fi > >@@ -709,7 +709,7 @@ > then > # grow new chunk to englobe current chunk. > arg_stop=$i_stop >- parsechunk=$(echo "$parsechunk" | "${TAIL}" +2) >+ parsechunk=$(echo "$parsechunk" | "${TAIL}" -n +2) > > break; # we can break because chunk are sorted. > fi >@@ -719,7 +719,7 @@ > then > # grow new chunk to englobe current chunk. > arg_start=$i_start >- parsechunk=$(echo "$parsechunk" | "${TAIL}" +2) >+ parsechunk=$(echo "$parsechunk" | "${TAIL}" -n +2) > continue; # new chunk might overlap more chunks > fi > >@@ -748,7 +748,7 @@ > # finding last's chunk end. > > if test "$chunk" ;then >- last_chunk=$(echo "$chunk" | "${TAIL}" -1 ) >+ last_chunk=$(echo "$chunk" | "${TAIL}" -n -1 ) > max_stop=$(echo "$last_chunk" | "${CUT}" -f 2 -d "-") > else > max_stop=0 >@@ -797,7 +797,7 @@ > function swallow_last_summary() > { > # last summary of log (4 lines output by printreport()) >- last_logcontent=$("${CAT}" "$logfile" | "$tr" -d "\\r" | "$GREP" "$string" -A 3 | "${TAIL}" -4) >+ last_logcontent=$("${CAT}" "$logfile" | "$tr" -d "\\r" | "$GREP" "$string" -A 3 | "${TAIL}" -n -4) > process_log "$last_logcontent" > > get_eof >@@ -811,7 +811,7 @@ > function get_last_chunk() > { > if test "$chunk"; then >- last_chunk="$(echo "$chunk" | "${TAIL}" -1 )" >+ last_chunk="$(echo "$chunk" | "${TAIL}" -n -1 )" > echo "$last_chunk" | "${CUT}" -f 2 -d "-" > else > echo 0 >@@ -978,7 +978,7 @@ > while test "$parsing" > do > firstline="$(echo "$parsing" | "${HEAD}" -1)" >- parsing="$(echo "$parsing" | "${TAIL}" +2)" >+ parsing="$(echo "$parsing" | "${TAIL}" -n +2)" > > xferd="$(echo "$firstline" | "${CUT}" -f 2 -d ":" | "${CUT}" -f 2 -d "=")" > errxfer="$(echo "$firstline" | "${CUT}" -f 4 -d ":" | "${CUT}" -f 2 -d "=")" >@@ -1070,7 +1070,7 @@ > > while test "$parsing" ;do > firstline="$(echo "$parsing" | "${HEAD}" -1)" >- parsing="$(echo "$parsing" | "${TAIL}" +2)" >+ parsing="$(echo "$parsing" | "${TAIL}" -n +2)" > > ipos="$(echo $firstline | "${CUT}" -f 1 -d ":" | "${CUT}" -f 2 -d "=")" > xferd="$(echo $firstline | "${CUT}" -f 2 -d ":" | "${CUT}" -f 2 -d "=")" >@@ -1107,19 +1107,19 @@ > # loading into memory Summary info found in log file... > # > # line number of last save_log entry... >- lnb_save=$("${CAT}" -n "$logfile" | "$tr" -d "\\r" | grep "chunk:" -A 2 | "${TAIL}" -3) >+ lnb_save=$("${CAT}" -n "$logfile" | "$tr" -d "\\r" | grep "chunk:" -A 2 | "${TAIL}" -n -3) > > > if test "$lnb_save" ;then > lnb_save=$(echo $lnb_save | "${HEAD}" -1 | cut -f 1 -d " ") > >- end_log="$(cat "$logfile" | "$tr" -d "\\r" | "${TAIL}" "+$lnb_save")" >+ end_log="$(cat "$logfile" | "$tr" -d "\\r" | "${TAIL}" -n "+$lnb_save")" > >- last_lines=$(echo "$end_log" | grep "chunk:" -A 2 | "${TAIL}" -3) >+ last_lines=$(echo "$end_log" | grep "chunk:" -A 2 | "${TAIL}" -n -3) > >- log=$(echo "$last_lines" | "$GREP" "chunk" | "${TAIL}" -1 ) >- log1=$(echo "$last_lines" | "$GREP" "logcontent" | "${TAIL}" -1 ) >- log2=$(echo "$last_lines" | "$GREP" "eof" | "${TAIL}" -1 ) >+ log=$(echo "$last_lines" | "$GREP" "chunk" | "${TAIL}" -n -1 ) >+ log1=$(echo "$last_lines" | "$GREP" "logcontent" | "${TAIL}" -n -1 ) >+ log2=$(echo "$last_lines" | "$GREP" "eof" | "${TAIL}" -n -1 ) > > if test "$log" && test "$log1" && test "$log2" ;then > chunk="$(echo "$log" | "${CUT}" -f 2- -d ":" | "${TR}" ":" "\n")"
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 221056
: 144595