Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 41926 Details for
Bug 67733
Evolution Palm Conduits - ISO8859-2 problem SOLVED (patch)
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Applies to app-pda/pilot-link. In the source: libpisock/util.c
iso8859-2.patch (text/plain), 2.68 KB, created by
Michael Dominic K.
on 2004-10-15 17:58:58 UTC
(
hide
)
Description:
Applies to app-pda/pilot-link. In the source: libpisock/util.c
Filename:
MIME Type:
Creator:
Michael Dominic K.
Created:
2004-10-15 17:58:58 UTC
Size:
2.68 KB
patch
obsolete
>/* > * sync.c: Implement generic synchronization algorithm > * > * Copyright (c) 2000, Helix Code Inc. > * > * Author: JP Rosevear <jpr@helixcode.com> > * > * This program is free software; you can redistribute it and/or modify it > * under the terms of the GNU General Public License as published by the > * Free Software Foundation; either version 2 of the License, or (at your > * option) any later version. > * > * This program is distributed in the hope that it will be useful, but > * WITHOUT ANY WARRANTY; without even the implied warranty of > * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General > * Public License for more details. > * > * You should have received a copy of the GNU General Public License along > * with this program; if not, write to the Free Software Foundation, Inc., > * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA > THIS FILE WAS PATCHED WITH ISO8859-2 PATCH FOR EVOLUTION CONDUITS */ > >#ifdef HAVE_CONFIG_H >#include <config.h> >#endif > >#include <stdlib.h> >#include <string.h> >#include <stdio.h> >#include "pi-util.h" > >#ifdef HAVE_ICONV >#include <iconv.h> >#endif > >#define PILOT_CHARSET "ISO8859-2" > >/*********************************************************************** > * > * Function: convert_ToPilotChar > * > * Summary: Convert any supported desktop text encoding to the Palm > * supported encoding > * > * Parameters: None > * > * Returns: 0 on success, -1 on failure > * > ***********************************************************************/ >int >convert_ToPilotChar(const char *charset, const char *text, > int bytes, char **ptext) >{ >#ifdef HAVE_ICONV > > char *ib, > *ob; > iconv_t cd; > size_t ibl, obl; > > > cd = iconv_open(PILOT_CHARSET, charset); > if (!cd) > return -1; > > ibl = bytes; > obl = bytes * 4 + 1; > ib = (char *)text; > *ptext = ob = malloc(obl); > > iconv(cd, &ib, &ibl, &ob, &obl); > *ob = '\0'; > > iconv_close(cd); > > return 0; > >#else > return -1; >#endif >} > >/*********************************************************************** > * > * Function: convert_FromPilotChar > * > * Summary: Convert from Palm supported encoding to a supported > * desktop text encoding > * > * Parameters: None > * > * Returns: 0 on success, -1 on failure > * > ***********************************************************************/ >int >convert_FromPilotChar(const char *charset, const char *ptext, > int bytes, char **text) >{ >#ifdef HAVE_ICONV > > char *ib, > *ob; > iconv_t cd; > size_t ibl, obl; > > cd = iconv_open(charset, PILOT_CHARSET); > if (!cd) > return -1; > > ibl = bytes; > obl = bytes * 4 + 1; > ib = (char *)ptext; > *text = ob = malloc(obl); > > iconv(cd, &ib, &ibl, &ob, &obl); > *ob = '\0'; > > iconv_close(cd); > > return 0; > >#else > return -1; >#endif >}
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 67733
:
41926
|
41983