~logan/ubuntu/quantal/julius/new-upstream

« back to all changes in this revision

Viewing changes to libsent/src/dfa/init_dfa.c

  • Committer: Bazaar Package Importer
  • Author(s): Siegfried-Angel Gevatter Pujals
  • Date: 2009-06-18 13:08:41 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20090618130841-d9elgw6tnu0ls5uh
Tags: 4.1.2-0ubuntu1
NOTE: If you have been using Julius before with "-input mic" and
with this update you notice a considerable accuracy drop in the
recognitions, try using "oss", "alsa" or "esd" instead of "mic".

* New upstream version. For a list of changes see Release.txt.
   - Fixes segfault when an empty .jconf file is used (LP: #298495).
   - Drop patches/fix-julius-manpage.patch, not necessary anymore.
   - Install accept_check and nextword, they work now.
* debian/patches/fix-japanese-manpages-install-dir.patch
   - Install Japanses manpages into usr/share/man/ja/man1 instead of
     usr/share/man/man1/ja.
* debian/doc/:
   - Disable all manpages in favour of upstreams, except for
     dfa_minimize, which has better examples, and julius-generate,
     which upstream doesn't ship.
* debian/rules:
   - Remove manpages for commands we don't ship and rename and adapt
     manpages for commands we renamed.
* debian/watch:
   - Fix it.
* debian/rules:
   - Do not install file ChangeLog, as it isn't up-to-date.
* debian/control:
   - Bump Standards-Version to 3.8.2.
* debian/copyright:
   - Specify that the packaging is GPLv2+.

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 * @author Akinobu LEE
21
21
 * @date   Tue Feb 15 14:20:43 2005
22
22
 *
23
 
 * $Revision: 1.2 $
 
23
 * $Revision: 1.3 $
24
24
 * 
25
25
 */
26
26
/*
162
162
  return TRUE;
163
163
}
164
164
 
165
 
/** 
166
 
 * Read grammar (DFA and dictionary) from socket and returns newly allocated
167
 
 * grammars.
168
 
 * 
169
 
 * @param sd [in] socket descpriter
170
 
 * @param ret_dfa [out] read DFA
171
 
 * @param ret_winfo [out] read dictionary
172
 
 * @param hmminfo [in] HMM definition
173
 
 * 
174
 
 * @return TRUE on success, or FALSE on failure.
175
 
 * </EN>
176
 
 */
177
 
boolean
178
 
read_grammar_from_socket(int sd, DFA_INFO **ret_dfa, WORD_INFO **ret_winfo, HTK_HMM_INFO *hmminfo)
179
 
{
180
 
  DFA_INFO *dfa;
181
 
  WORD_INFO *winfo;
182
 
 
183
 
  /* load grammar: dfa and dict in turn */
184
 
  dfa = dfa_info_new();
185
 
  if (!
186
 
#ifdef WINSOCK
187
 
      rddfa_sd(sd, dfa)
188
 
#else
189
 
      rddfa_fd(sd, dfa)
190
 
#endif
191
 
      ) {
192
 
    return FALSE;
193
 
  }
194
 
  winfo = word_info_new();
195
 
  /* ignore MONOTREE */
196
 
  if (!
197
 
#ifdef WINSOCK
198
 
      voca_load_htkdict_sd(sd, winfo, hmminfo, FALSE)
199
 
#else
200
 
      voca_load_htkdict_fd(sd, winfo, hmminfo, FALSE)
201
 
#endif
202
 
      ) {
203
 
    dfa_info_free(dfa);
204
 
    return FALSE;
205
 
  }
206
 
  *ret_dfa = dfa;
207
 
  *ret_winfo = winfo;
208
 
  return TRUE;
209
 
}