aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel/src/mosflm.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2012-08-08 11:20:14 +0200
committerThomas White <taw@physics.org>2012-10-02 15:02:12 +0200
commite67a04b7492806816f2c5ecbadd9814eb33068e1 (patch)
tree7c546be27b2eed3a10138de40377aae0cb6fffb4 /libcrystfel/src/mosflm.c
parent49e99dd17d003df568ef676a2c5b66ed82193dc7 (diff)
WIP
Diffstat (limited to 'libcrystfel/src/mosflm.c')
-rw-r--r--libcrystfel/src/mosflm.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/libcrystfel/src/mosflm.c b/libcrystfel/src/mosflm.c
index a2d8520e..e81f20b6 100644
--- a/libcrystfel/src/mosflm.c
+++ b/libcrystfel/src/mosflm.c
@@ -276,6 +276,8 @@ static const char *spacegroup_for_lattice(UnitCell *cell)
{
LatticeType latt;
char centering;
+ char *g = NULL;
+ char *result;
latt = cell_get_lattice_type(cell);
centering = cell_get_centering(cell);
@@ -291,7 +293,7 @@ static const char *spacegroup_for_lattice(UnitCell *cell)
break;
case L_ORTHORHOMBIC :
- g = "222";
+ g = "2 2 2";
break;
case L_TETRAGONAL :
@@ -307,11 +309,17 @@ static const char *spacegroup_for_lattice(UnitCell *cell)
break;
case L_CUBIC :
- g = "23";
+ g = "2 3";
break;
+ }
+ assert(g != NULL);
+
+ result = malloc(32);
+ if ( result == NULL ) return NULL;
+ snprintf(result, 31, "%c %s", centering, g);
- return "P1";
+ return result;
}