scm: init. Fix a crash on new project initializing SCM.

The code was checking for an engine which doesn't exist and thus
crashing. This fixes that.

@fix
This commit is contained in:
Alastair Poole 2018-05-13 12:50:21 +01:00 committed by Andy Williams
parent a98145046a
commit ea6b0ab193
1 changed files with 3 additions and 2 deletions

View File

@ -594,12 +594,13 @@ _edi_project_credentials_check(void)
Edi_Scm_Engine *eng;
eng = edi_scm_engine_get();
if ((!_edi_project_config->user_fullname || strlen(_edi_project_config->user_fullname) == 0) &&
!eng->remote_name_get())
eng && !eng->remote_name_get())
return EINA_FALSE;
if ((!_edi_project_config->user_email || strlen(_edi_project_config->user_email) == 0) &&
!eng->remote_email_get())
eng && !eng->remote_email_get())
return EINA_FALSE;
return EINA_TRUE;