X-Received: by 10.66.89.74 with SMTP id bm10mr1990219pab.19.1358766021925; Mon, 21 Jan 2013 03:00:21 -0800 (PST) X-Received: by 10.50.171.100 with SMTP id at4mr2638549igc.6.1358766021881; Mon, 21 Jan 2013 03:00:21 -0800 (PST) Path: csiph.com!aioe.org!news.glorb.com!f6no4620161pbd.1!news-out.google.com!s9ni7905pbb.0!nntp.google.com!f6no4620157pbd.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.os.os2.programmer.porting Date: Mon, 21 Jan 2013 03:00:21 -0800 (PST) In-Reply-To: <0KhBVN5juOdd-pn2-HFexfnyGshOl@neo_iii> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=106.51.128.65; posting-account=m2xB5QoAAACXVH6iEmb8TAhbyPsq1kbw NNTP-Posting-Host: 106.51.128.65 References: <0KhBVN5juOdd-pn2-Od3ScT2CWGXd@neo_iii> <0KhBVN5juOdd-pn2-W6Dh9n8j6eZW@neo_iii> <0KhBVN5juOdd-pn2-uewIjdkqIdes@neo_iii> <0KhBVN5juOdd-pn2-etRSoGxQzz6z@neo_iii> <0KhBVN5juOdd-pn2-zuHodgfNGl5U@neo_iii> <4e19f24a$0$6584$9b4e6d93@newsspool3.arcor-online.net> <0KhBVN5juOdd-pn2-HFexfnyGshOl@neo_iii> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <9c36b679-1404-476c-8290-64b4287062ee@googlegroups.com> Subject: Re: SOLVED!: Problem: error in iconv_open From: vsvidya7@gmail.com Injection-Date: Mon, 21 Jan 2013 11:00:21 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: csiph.com comp.os.os2.programmer.porting:218 On Monday, 11 July 2011 04:03:27 UTC+5:30, Mentore Siesto wrote: > Il giorno Sun, 10 Jul 2011 18:41:13 UTC, "Lars Erdmann" > ha scritto: > > > Hallo, > > > > > It was not the random number generator. I built another release using > > > another generator, which uses a specific algorithm, and noticed the > > > very same problem. So I checked out the fopen () calls, as the program > > > worked fine with text file, and guess what? > > > > > > Yes, the original source opens files without the "binary" flag. adding > > > "b" to all the fopen () calls solved the problem. > > > > Use of "fopen": > > The usual pitfall when porting UNIX type programs to Windows or OS/2. > > UNIX makes no distinction between text and binary files. Therefore it opens > > all files as binary files (even though in the C-RTL you can specify binary > > or text). > > Windows and OS/2 on the other hand open files as text files as a default. > > (unless the C-RTL specifies otherwise). > > > > Lars > > Well, this time the problem was that I was ought to find a suitable > random number generator and create arrays of 32 unsigned char. The > conversion between unsigned int and unsigned char made me think > probably I was making a mistake in typecasting, that's why I didn't > think about fopen. > > After a while I asked myself why it worked on text files, and voila, > the solution came. > > Mentore Hi Sir, I am working on the jpeg image file encryption and decryption, for this downloaded the source code from link :http://www.aescrypt.com/linux_aes_crypt.html for linux . I cross compiled this code package and for arm-none-linux-gnueabi-gcc compiler. But i am getting run time error "Error in iconv_open: Invalid argument" . How this error i can solve and which library supports the UTF-16 in LINUX (ubuntu-10.10) please help me. Processor : DM3730. Thanks, Vidya