Projects >> android_packages_apps_Bluetooth >>aefbc8ce31a4da1dd6b0ebcd322ddcdf031093e6

Chunk
Conflicting content
        @Override
        public void run() {
<<<<<<< HEAD

            Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND);
            ContentValues updateValues;
=======

            ContentValues updateValues;

            Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND);
>>>>>>> f685a8d702a0a69a0e872e8b0bb9ffee3f9aa59c
            if (V) Log.v(TAG, "Is ContentResolverUpdateThread Interrupted :" + isInterrupted());
            /*  Check if the Operation is interrupted before entering into loop */
            while (!isInterrupted()) {
Solution content
        @Override
        public void run() {

            Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND);
            ContentValues updateValues;
            if (V) Log.v(TAG, "Is ContentResolverUpdateThread Interrupted :" + isInterrupted());
            /*  Check if the Operation is interrupted before entering into loop */
            while (!isInterrupted()) {
File
BluetoothOppObexClientSession.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Variable
Chunk
Conflicting content
                                if (uiUpdateThread == null) {
                                    uiUpdateThread = new ContentResolverUpdateThread (mContext1,
<<<<<<< HEAD
                                                                    contentUri);
=======
                                                             contentUri);
>>>>>>> f685a8d702a0a69a0e872e8b0bb9ffee3f9aa59c
                                    if (V) Log.v(TAG, "Worker for Updation : Created");
                                    uiUpdateThread.start ( );
                                }
Solution content
                                if (uiUpdateThread == null) {
                                    uiUpdateThread = new ContentResolverUpdateThread (mContext1,
                                                                    contentUri);
                                    if (V) Log.v(TAG, "Worker for Updation : Created");
                                    uiUpdateThread.start ( );
                                }
File
BluetoothOppObexClientSession.java
Developer's decision
Version 1
Kind of conflict
Attribute
Chunk
Conflicting content
    }

    private class ContentResolverUpdateThread extends Thread {
<<<<<<< HEAD
        private static final int sSleepTime = 1000;
        private Uri contentUri;
        private Context mContext1;

=======

        private static final int sSleepTime = 1000;
        private Uri contentUri;
        private Context mContext1;
        private volatile boolean interrupted = false;
>>>>>>> f685a8d702a0a69a0e872e8b0bb9ffee3f9aa59c
        public ContentResolverUpdateThread(Context context, Uri cntUri) {
            super("BtOpp Server ContentResolverUpdateThread");
            mContext1 = context;
Solution content
    }

    private class ContentResolverUpdateThread extends Thread {
        private static final int sSleepTime = 1000;
        private Uri contentUri;
        private Context mContext1;

        public ContentResolverUpdateThread(Context context, Uri cntUri) {
            super("BtOpp Server ContentResolverUpdateThread");
            mContext1 = context;
File
BluetoothOppObexServerSession.java
Developer's decision
Version 1
Kind of conflict
Attribute
Chunk
Conflicting content
            Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND);
            ContentValues updateValues;
<<<<<<< HEAD

            if (V) Log.v(TAG, "Is ContentResolverUpdateThread Interrupted :" + isInterrupted());
            /*  Check if the Operation is interrupted before entering into loop */
            while ( !isInterrupted() ) {

                updateValues = new ContentValues();
                updateValues.put(BluetoothShare.CURRENT_BYTES, position);
                mContext1.getContentResolver().update(contentUri, updateValues,
                        null, null);
                /* Check if the Operation is interrupted before entering sleep */
                if (isInterrupted()) {
                    if (V) Log.v(TAG, "ContentResolverUpdateThread was interrupted before sleep !,"+
                                     " exiting");
                    return ;
                }
                try {
                    Thread.sleep(sSleepTime);
                } catch (InterruptedException e1) {
                    if (V) Log.v(TAG, "Server ContentResolverUpdateThread was interrupted (1),"+
                                     " exiting");
                   return ;
              }
           }
       }
=======
            if (V) Log.v(TAG, "Is ContentResolverUpdateThread Interrupted :" + isInterrupted());
            /*  Check if the Operation is interrupted before entering into loop */
            while ( !isInterrupted() ) {
               updateValues = new ContentValues();
               updateValues.put(BluetoothShare.CURRENT_BYTES, position);
               mContext1.getContentResolver().update(contentUri, updateValues,
                   null, null);
               /* Check if the Operation is interrupted before entering sleep */
               if (isInterrupted()) {
                   if (V) Log.v(TAG, "ContentResolverUpdateThread was interrupted before sleep !,"+
                                     " exiting");
                   return ;
               }

               try {
                   Thread.sleep(sSleepTime);
               } catch (InterruptedException e1) {
                   if (V) Log.v(TAG, "Server ContentResolverUpdateThread was interrupted (1),"+
                                     " exiting");
                   return ;
               }
            }
        }
>>>>>>> f685a8d702a0a69a0e872e8b0bb9ffee3f9aa59c
    }
    /*
    * Called when a ABORT request is received.
Solution content
            Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND);
            ContentValues updateValues;

            if (V) Log.v(TAG, "Is ContentResolverUpdateThread Interrupted :" + isInterrupted());
            /*  Check if the Operation is interrupted before entering into loop */
            while ( !isInterrupted() ) {

                updateValues = new ContentValues();
                updateValues.put(BluetoothShare.CURRENT_BYTES, position);
                mContext1.getContentResolver().update(contentUri, updateValues,
                        null, null);
                /* Check if the Operation is interrupted before entering sleep */
                if (isInterrupted()) {
                    if (V) Log.v(TAG, "ContentResolverUpdateThread was interrupted before sleep !,"+
                                     " exiting");
                    return ;
                }
                try {
                    Thread.sleep(sSleepTime);
                } catch (InterruptedException e1) {
                    if (V) Log.v(TAG, "Server ContentResolverUpdateThread was interrupted (1),"+
                                     " exiting");
                   return ;
              }
           }
       }
    }
    /*
    * Called when a ABORT request is received.
File
BluetoothOppObexServerSession.java
Developer's decision
Version 1
Kind of conflict
Comment
If statement
While statement