<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=US-ASCII" http-equiv="Content-Type">
<title>
GitLab
</title>



<style>img {
max-width: 100%; height: auto;
}
</style>
</head>
<body>
<div class="content">

<p style="color: #777777;">
<a href="https://gitlab.com/dueno">Daiki Ueno</a>
started a new
discussion on <a href="https://gitlab.com/gnutls/gnutls/-/merge_requests/1300#note_395423261">devel/import-ecc-from-nettle.sh</a>:
</p>
<table>
<tr class="line_holder" id="">
<td class="diff-line-num old_line" data-linenumber="202" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
202
</td>
<td class="diff-line-num new_line" data-linenumber="202" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
202
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC202" class="line" lang="shell">        <span class="p">;;</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="">
<td class="diff-line-num old_line" data-linenumber="203" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
203
</td>
<td class="diff-line-num new_line" data-linenumber="203" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
203
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC203" class="line" lang="shell">      <span class="k" style="font-weight: 600;">*</span>/ecc-random.c <span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="">
<td class="diff-line-num old_line" data-linenumber="204" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
204
</td>
<td class="diff-line-num new_line" data-linenumber="204" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
204
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC204" class="line" lang="shell">        <span class="nb" style="color: #0086b3;">sed</span> <span class="se" style="color: #d14;">\</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="">
<td class="diff-line-num old old_line" data-linenumber="205" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
205
</td>
<td class="diff-line-num new_line old" data-linenumber="205" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC205" class="line" lang="shell">          <span class="nt" style="color: #000080;">-e</span> <span class="s1" style="color: #d14;">'s/"nettle-internal\.h"/"nettle-alloca.h"/'</span> <span class="se" style="color: #d14;">\</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="">
<td class="diff-line-num new old_line" data-linenumber="206" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="205" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
205
</td>
<td class="line_content new" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC205" class="line" lang="shell">          <span class="nt" style="color: #000080;">-e</span> <span class="s1" style="color: #d14;">'s/"nettle-internal\.h"/"nettle-alloca.h"<span class="idiff left right">\nvoid ecc_scalar_random(struct ecc_scalar \*, void \*, nettle_random_func \*);</span>/'</span> <span class="se" style="color: #d14;">\</span></span>
</pre>
</td>
</tr>

</table>
<div style="">
<p dir="auto">Using a backslash escape (<code>\n</code>) in replacement is not portable, for example:</p>
<pre class="code highlight js-syntax-highlight console" lang="console" v-pre="true" style="background-color: #fff; font-family: monospace; font-size: 90%; -premailer-cellpadding: 0; -premailer-cellspacing: 0; -premailer-width: 100%; margin: 0;"><code><span id="LC1" class="line" lang="console"><span class="gp" style="color: #555;">ueno@gcc-solaris10:~$</span><span class="w" style="color: #bbb;"> </span><span class="nb" style="color: #0086b3;">echo </span>a <span class="o" style="font-weight: 600;">></span> a</span>
<span id="LC2" class="line" lang="console"><span class="gp" style="color: #555;">ueno@gcc-solaris10:~$</span><span class="w" style="color: #bbb;"> </span><span class="nb" style="color: #0086b3;">sed</span> <span class="s1" style="color: #d14;">'s/a/"bar"\n"foo"/'</span> a</span>
<span id="LC3" class="line" lang="console"><span class="go" style="color: #888;">"bar"n"foo"</span></span></code></pre>
<p dir="auto">I'd suggest using <code>i</code> and <code>d</code> combination as in:
<a href="https://gitlab.com/gnutls/gnutls/-/blob/master/devel/import-from-nettle.sh#L134">https://gitlab.com/gnutls/gnutls/-/blob/master/devel/import-from-nettle.sh#L134</a></p>
</div>


</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #777;">

<br>
Reply to this email directly or <a href="https://gitlab.com/gnutls/gnutls/-/merge_requests/1300#note_395423261">view it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.com.
If you'd like to receive fewer emails, you can
<a href="https://gitlab.com/-/sent_notifications/15c9fe12d425cdb5ac06a809a678015a/unsubscribe">unsubscribe</a>
from this thread or
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Merge request","url":"https://gitlab.com/gnutls/gnutls/-/merge_requests/1300#note_395423261"}}</script>


</p>
</div>
</body>
</html>