mirror of
https://github.com/lh3/minimap2.git
synced 2026-10-03 18:08:13 +08:00
get multi-seg code ready; probably not working yet
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
#define MM_BSEQ_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@@ -24,6 +25,17 @@ int mm_bseq_eof(mm_bseq_file_t *fp);
|
||||
|
||||
extern unsigned char seq_nt4_table[256];
|
||||
|
||||
static inline int mm_qname_same(const char *s1, const char *s2)
|
||||
{
|
||||
int l1, l2;
|
||||
l1 = strlen(s1);
|
||||
l2 = strlen(s2);
|
||||
if (l1 != l2 || l1 < 3) return 0;
|
||||
if (!(s1[l1-1] >= '1' && s1[l1-1] <= '2' && s1[l1-2] == '/')) return 0;
|
||||
if (!(s2[l2-1] >= '1' && s2[l2-1] <= '2' && s2[l2-2] == '/')) return 0;
|
||||
return (strncmp(s1, s2, l1 - 2) == 0);
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user