Re: [gedit-list] Fwd: =0A=
- From: Doug McNutt <douglist macnauchtan com>
- To: gedit-list gnome org
- Subject: Re: [gedit-list] Fwd: =0A=
- Date: Mon, 11 Mar 2013 12:16:58 -0600
At 17:32 +0100 3/11/13, Adam wrote:
On 10.03.2013 23:32, Doug McNutt wrote:
At 19:10 +0100 3/10/13, Adam wrote:
I have recevied a c code.
Every line has a =0A=at the end of the line.
Does it mean that it is windows EOF char ?
What is the best way to remove it ?
At 18:32 -0300 3/10/13, Matheus Boy wrote:
0x0A is ASCII for LF, Line Feed, '\n'.
My piece of advice: don't remove those chars, try changing the encoding of the file.
BTW, EOF in ASCII is 0x04.
2013/3/10 Adam <<mailto:adammaj1 o2 pl>adammaj1 o2 pl>
The =0A item looks a lot like "quoted printable" as a feature of email special encoding for otherwise
unrecognized binary items that are not printable in the current user's machine.
Of course we, and likely you, don't know the sender's machine's OS.
You probably need to decode the data and gedit isn't very good at that. If the file opens without gedit
complaining the "line" probably ends with =0A\n but it might be =0A\r\n with gedit accepting the official
internet linend character pair \r\n.
hexdump or just hd piped to gedit using Terminal.app would show the facts.
hd PathToTheFile | gedit
You can probably just delete the ASCII character string "=0A" with gedit's search and replace but do try it
with a copy.
You might be able to recover by substituting ";\n" for every semicolon if it's really a simple source code
in C.
Thx.
Here is a fragment of file ( maybe it will help ):
/* by ........ 2005=0A=
all parts of this program are under the GNU GPL */=0A=
=0A=
#include <stdio.h>=0A=
#include <stdlib.h>=0A=
#include <math.h>=0A=
#include <float.h>=0A=
=0A=
#include "complex.h"=0A=
#include "zero.h"=0A=
=0A=
=0A=
another part with ; :
=0A=
dz =3D c_div (y, y1);=0A=
=0A=
I have tried hd :
00000020 20 20 61 6c 6c 20 70 61 72 74 73 20 6f 66 20 74 | all parts of t|
00000030 68 69 73 20 70 72 6f 67 72 61 6d 20 61 72 65 20 |his program are |
00000040 75 6e 64 65 72 20 74 68 65 20 47 4e 55 20 47 50 |under the GNU GP|
00000050 4c 20 2a 2f 3d 30 41 3d 0d 0a 3d 30 41 3d 0d 0a |L */=0A=..=0A=..|
00000060 23 69 6e 63 6c 75 64 65 20 3c 73 74 64 69 6f 2e |#include <stdio.|
00000070 68 3e 3d 30 41 3d 0d 0a 23 69 6e 63 6c 75 64 65 |h>=0A=..#include|
00000080 20 3c 73 74 64 6c 69 62 2e 68 3e 3d 30 41 3d 0d | <stdlib.h>=0A=.|
The =3D proves the quoted printable analysis. 3D is the ASCII = sign which is used to introduce the pairs
of hex digits that allow for transmission of ASCII characters that are not printable - meaning that they
don't have a grapheme associated with them in a font. Because the = sigh has special meaning it has to be
encoded as if it were unprintable.
Have a look here.
<http://www.webatic.com/run/convert/qp.php>
I just pasted your last few lines in and received:
*****Begin copy ***
/* by ........ 2005
all parts of this program are under the GNU GPL */
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <float.h>
#include "complex.h"
#include "zero.h"
another part with ; :
dz = c_div (y, y1);
***end copy***
My guess is that you could just remove all "=0A" triplets followed by changing =3D to just = and then
removing all = signs that appear at an end of a line. Another place you might look is:
<en.wikipedia.org/wiki/Quoted-printable>
--
--> A fair tax is one that you pay but I don't <--
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]