~ubuntu-branches/ubuntu/vivid/psicode/vivid

« back to all changes in this revision

Viewing changes to src/lib/libchkpt/sprim.c

  • Committer: Bazaar Package Importer
  • Author(s): Michael Banck
  • Date: 2008-06-07 16:49:57 UTC
  • mfrom: (2.1.2 hardy)
  • Revision ID: james.westby@ubuntu.com-20080607164957-8pifvb133yjlkagn
Tags: 3.3.0-3
* debian/rules (DEB_MAKE_CHECK_TARGET): Do not abort test suite on
  failures.
* debian/rules (DEB_CONFIGURE_EXTRA_FLAGS): Set ${bindir} to /usr/lib/psi.
* debian/rules (install/psi3): Move psi3 file to /usr/bin.
* debian/patches/07_464867_move_executables.dpatch: New patch, add
  /usr/lib/psi to the $PATH, so that the moved executables are found.
  (closes: #464867)
* debian/patches/00list: Adjusted.

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
*/
5
5
 
6
6
#include <stdio.h>
 
7
#include <stdlib.h>
7
8
#include <libciomr/libciomr.h>
8
9
#include "chkpt.h"
9
10
#include <psifiles.h>
25
26
{
26
27
  int *sprim;
27
28
  int nshell;
 
29
  char *keyword;
 
30
  keyword = chkpt_build_keyword("First primitive per shell");
28
31
 
29
32
  nshell = chkpt_rd_nshell();
30
33
 
31
34
  sprim = init_int_array(nshell);
32
35
 
33
 
  psio_read_entry(PSIF_CHKPT, "::First primitive per shell", (char *) sprim, 
34
 
                  nshell*sizeof(int));
 
36
  psio_read_entry(PSIF_CHKPT, keyword, (char *) sprim, nshell*sizeof(int));
35
37
 
 
38
  free(keyword);
36
39
  return sprim;
37
40
}
38
41
 
52
55
void chkpt_wt_sprim(int *sprim)
53
56
{
54
57
  int nshell;
 
58
  char *keyword;
 
59
  keyword = chkpt_build_keyword("First primitive per shell");
55
60
 
56
61
  nshell = chkpt_rd_nshell();
57
62
 
58
 
  psio_write_entry(PSIF_CHKPT, "::First primitive per shell", (char *) sprim, 
59
 
                   nshell*sizeof(int));
 
63
  psio_write_entry(PSIF_CHKPT, keyword, (char *) sprim, nshell*sizeof(int));
 
64
 
 
65
  free(keyword);
60
66
}